-
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
原生混写模版中import的依赖没有全部编译输出 #5824
Comments
CC @luckyadam |
欢迎提交 Issue~ 如果你提交的是 bug 报告,请务必遵循 Issue 模板的规范,尽量用简洁的语言描述你的问题,最好能提供一个稳定简单的复现。🙏🙏🙏 如果你的信息提供过于模糊或不足,或者已经其他 issue 已经存在相关内容,你的 issue 有可能会被关闭。 Good luck and happy coding~ |
这么久了都不解决一下吗。。 |
wzono
pushed a commit
to wzono/taro
that referenced
this issue
Aug 26, 2020
wzono
pushed a commit
to wzono/taro
that referenced
this issue
Aug 26, 2020
20 tasks
wzono
pushed a commit
to wzono/taro
that referenced
this issue
Aug 27, 2020
20 tasks
luckyadam
pushed a commit
that referenced
this issue
Aug 27, 2020
This was referenced Sep 18, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
问题描述
Taro 代码与小程序代码混写时,模版xml有多个一级节点时,模版中的依赖没有正确编译输出。
复现步骤
<import src="..." />
示例问题模版,仅有a.swan会被输出:
期望行为
import的依赖都被编译输出
报错信息
无报错信息,编译产物缺失
系统信息
Taro CLI 2.0.7 environment info:
System:
OS: macOS 10.15.3
Shell: 5.7.1 - /bin/zsh
Binaries:
Node: 12.16.1 - ~/.nvm/versions/node/v12.16.1/bin/node
Yarn: 1.22.4 - /usr/local/bin/yarn
npm: 6.13.4 - ~/.nvm/versions/node/v12.16.1/bin/npm
npmPackages:
@tarojs/components: 2.0.7 => 2.0.7
@tarojs/components-qa: 2.0.7 => 2.0.7
@tarojs/mini-runner: 2.0.7 => 2.0.7
@tarojs/router: 2.0.7 => 2.0.7
@tarojs/taro: 2.0.7 => 2.0.7
@tarojs/taro-alipay: 2.0.7 => 2.0.7
@tarojs/taro-h5: 2.0.7 => 2.0.7
@tarojs/taro-qq: 2.0.7 => 2.0.7
@tarojs/taro-quickapp: 2.0.7 => 2.0.7
@tarojs/taro-rn: 2.0.7 => 2.0.7
@tarojs/taro-swan: 2.0.7 => 2.0.7
@tarojs/taro-tt: 2.0.7 => 2.0.7
@tarojs/taro-weapp: 2.0.7 => 2.0.7
@tarojs/webpack-runner: 2.0.7 => 2.0.7
eslint-config-taro: 2.0.7 => 2.0.7
eslint-plugin-taro: 2.0.7 => 2.0.7
nerv-devtools: ^1.5.5 => 1.5.6
nervjs: ^1.5.5 => 1.5.6
stylelint-config-taro-rn: 2.0.7 => 2.0.7
stylelint-taro-rn: 2.0.7 => 2.0.7
补充信息
taro/packages/taro-mini-runner/src/loaders/miniTemplateLoader.ts
Line 22 in b4bb27c
sax
模块onattribute
只被触发了一次。原因是sax
仅会解析第一个一级节点,可能是sax
的bug。需要替换
sax
模块,或者将source
整体包装在一个根节点中:taro/packages/taro-mini-runner/src/loaders/miniTemplateLoader.ts
Line 41 in b4bb27c
改为
The text was updated successfully, but these errors were encountered: