-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
fix(helper): 修复 esbuild resolve 静态资源问题 #13918
Conversation
但是单单修复这个还不够,看这里的 dev:weapp 模式打包的 dist/app.js 文件 会有 .wsxx 文件被 require 引入,查询了微信小程序文档,其不支持直接
<import src="file_path.wxss"/>
"style": "path/to/file.wxss" |
使用 3.6.9-alpha.5 后,运行 $ % taro info
👽 Taro v3.6.8
Taro CLI 3.6.8 environment info:
System:
OS: macOS 13.0
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 18.15.0 - ~/.nvm/versions/node/v18.15.0/bin/node
Yarn: 1.22.19 - ~/.nvm/versions/node/v18.15.0/bin/yarn
npm: 9.5.0 - ~/.nvm/versions/node/v18.15.0/bin/npm
npmPackages:
@tarojs/cli: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/components: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/helper: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/plugin-framework-vue3: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/plugin-html: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/plugin-platform-alipay: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/plugin-platform-h5: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/plugin-platform-jd: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/plugin-platform-qq: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/plugin-platform-swan: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/plugin-platform-tt: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/plugin-platform-weapp: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/runtime: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/shared: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/taro: 3.6.9-alpha.5 => 3.6.9-alpha.5
@tarojs/webpack5-runner: 3.6.9-alpha.5 => 3.6.9-alpha.5
babel-preset-taro: 3.6.9-alpha.5 => 3.6.9-alpha.5
eslint-config-taro: 3.6.9-alpha.5 => 3.6.9-alpha.5 |
使用 nutui@4 确实有这个问题 |
我这里提供一下我的必现场景,当引用的第三方包,其入口文件有 import 'path/to/file.(css|less|scss...)' 非 js 模块,就能复现这个问题 |
This comment was marked as off-topic.
This comment was marked as off-topic.
|
这个 PR 做了什么? (简要描述所做更改)
生产环境下,esbuild.onResolve 解析静态资源会在 file namespace 中完成,需要在设置为外部依赖时解析路径。
这个 PR 是什么类型? (至少选择一个)
这个 PR 涉及以下平台: