-
Notifications
You must be signed in to change notification settings - Fork 3k
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
slot必须和父元素的开始标签隔字符才可以解析成功 #801
Comments
使用一模一样的代码但是并没有复现问题。 |
@Gcaufy
期望看到的是红底的 Hello,但实际效果是只有 Hello,外层 view 消失了。在子组件复杂嵌套情况下,还可能导致各种丢失元素。 |
这是xmldom的一个BUG,已提交PR,jindw/xmldom#229 |
我在自定义组件标签中放入了另外一个自定义组件作为slot,结果只渲染了slot的内容,外层的东西全没了,加了 |
@fantasy525 可以看一下上面提到的 PR 里的修复办法,自己在本地改一下 xmldom 的源码。 |
我也遇到这个问题,现在解决办法是加入换行符解决,比如 这样定义的组件,在wepy编译后,button标签没有了 这样写正常了~~~~
|
Edited:
现在发现隔字符就能解析,所以这样解决了:
The text was updated successfully, but these errors were encountered: