SAP 电商云 Spartacus UI 的 slot,posi
2021-11-25 本文已影响0人
华山令狐冲
在 for 循环里进行的渲染:

最后渲染出来这些 Component 都位于 position 的 slot 内:

slot 和 position 一一对应:

slot 里面又循环 Component:

在 page-slot.component.html 加上一行调试信息:
<div>component id: {{ component.uid }}</div>

最后出来的结果:

再把 position 也打印出来:

最后的结果:

更多Jerry的原创文章,尽在:"汪子熙":
