多页面出码怎么实现
多页面出码的schema结构是什么样的
To Reproduce (required) / 如何复现 bug?(必填,非常重要)
拓展comonentsTree,能够实现多页面出码,但是每个页面怎么和componentsMap对应呢?
就是如图所示,当 componentsTree 为多个元素时,各个 tree 中所使用到的组件均被加入到 componentsMap 中,即共用的关系~
在出码引擎针对 Page / Component 类型的容器时,会根据当前容器里 componentName 收集使用到的组件,最终反应在 ir.deps 中~
参照代码 SchemaParser.ts
有没有一个方法,我传入页面的schema、然后得到这个页面的 componentsMap,这样我就可以进行多页面的合并、等操作了。
componentsTree 和 componentsMap 在页面 exportSchema 时就是同时导出的,出码前将多个 tree 和 map 做个 merge,tree 应该直接 push,map 应该要去重判断下
就是如图所示,当 componentsTree 为多个元素时,各个 tree 中所使用到的组件均被加入到 componentsMap 中,即共用的关系~
在出码引擎针对 Page / Component 类型的容器时,会根据当前容器里 componentName 收集使用到的组件,最终反应在 ir.deps 中~
参照代码 SchemaParser.ts
你们官方文档纯纯的误导人,我照着官方文档组织了schema,然后router根本没变化,看了源代码才知道是看page里的meat生成的。真的坑
Hi,有解决方案吗,这个应用的路由是要怎么用的?