Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug 上报] wd-text 未兼容 CLI 工程,报错 Cannot find module ... wd-text.vue #453

Closed
normal-coder opened this issue Jul 20, 2024 · 1 comment
Labels

Comments

@normal-coder
Copy link
Contributor

Wot Design Uni 版本号

1.3.4

平台

h5, 微信小程序, 支付宝小程序, APP, 钉钉小程序, 其他小程序

复现Demo地址

无须复现 DEMO,从工程结构中可直接发现。

重现步骤

在 CLI 环境中使用 wd-text 组件,wd-text 组件会尝试从 uni_module 引入 dayjs,进而引起报错。

3:20:40 PM [vite] [plugin:vite:import-analysis] Cannot find module '/Users/normal/***********/src/uni_modules/wot-design-uni' from '/Users/normal/***********/node_modules/wot-design-uni/components/wd-text/wd-text.vue'
at ../node_modules/wot-design-uni/components/wd-text/wd-text.vue:1:0
3:20:40 PM [vite] [plugin:vite:import-analysis] Cannot find module '/Users/normal/github/***********/src/uni_modules/wot-design-uni' from '/Users/normal/***********/node_modules/wot-design-uni/components/wd-text/wd-text.vue'
at ../node_modules/wot-design-uni/components/wd-text/wd-text.vue:1:0 (x2)

期望的结果是什么?

wd-text 组件可在 CLI 下正常使用

实际的结果是什么?

当前引入报错。

环境信息

此缺陷与环境无关

其他补充信息

@normal-coder normal-coder added the 🐞bug: need confirm 待确认的bug label Jul 20, 2024
@normal-coder normal-coder changed the title [Bug 上报] 请在此填写标题 [Bug 上报] wd-text 未兼容 CLI 工程,报错 Cannot find module ... wd-text.vue Jul 20, 2024
@Moonofweisheng Moonofweisheng added 🐞bug bug and removed 🐞bug: need confirm 待确认的bug labels Jul 20, 2024
Copy link

此 issue 已被自动锁定,因为关闭后没有任何近期活动。如果有相关 bug,请重新创建一个新 issue。

@github-actions github-actions bot locked and limited conversation to collaborators Aug 19, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants