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

小程序最多支持几层的slot嵌套 #28

Closed
xxvv opened this issue Feb 1, 2019 · 1 comment
Closed

小程序最多支持几层的slot嵌套 #28

xxvv opened this issue Feb 1, 2019 · 1 comment
Labels
Q&A some valuable case

Comments

@xxvv
Copy link

xxvv commented Feb 1, 2019

bug描述
使用组件展示异常

复现bug的步骤
组件a 嵌套组件b,组件b中放入元素,这里嵌套了多层slot

*问题截图
本来应该隐藏的也展示了
image

image
b组件没有渲染class
image
image

编译环境信息

  • chameleon-tool 版本:[0.0.13]
  • nodejs版本、npm版本:[node v9.9.0、npm 6.5.0]
  • 电脑操作系统: [window 10]

运行环境信息

  • 端版本: [微信小程序 1.02.1901230]
@xxvv xxvv added the bug Something isn't working label Feb 1, 2019
@jimwmg
Copy link
Collaborator

jimwmg commented Feb 1, 2019

您好:
1 $slots是只在vue端才有的 ,小程序组件中没有 $slots这样的属性
2 注意下代码中语法的规范,如果是 cml 语法,那么是 c-if="{{variable}}" 这样的写法,如果是类 vue语法 是 v-if="variable";
3 如果使用类vue语法,需要在 template根元素上加 lang='vue'属性;

@MicroConan MicroConan added invalid This doesn't seem right and removed bug Something isn't working labels Feb 14, 2019
@startheart startheart added Q&A some valuable case and removed invalid This doesn't seem right labels May 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Q&A some valuable case
Projects
None yet
Development

No branches or pull requests

5 participants