WebCell
WebCell copied to clipboard
支持IE11的slot处理和ssr吗
支持slot低版本和ssr处理吗
- Web Components 官方 polyfill 对 IE 11
<slot />的支持貌似还有问题:https://stackoverflow.com/questions/66393616/angular11-webcomponents-polyfills-ie11-nojoy - SSR 的支持我正在研究标准提案:https://web.dev/declarative-shadow-dom/
新标准 ElementInternals 提供了对 <template shadowRootMode="open" /> 的支持,因此 WebCell v3 基于此提供了对 SSR 的组件引擎级支持:
https://github.com/EasyWebApp/WebCell/blob/619146c9e2edb96d80e7086e5a4362b6c0adb25c/source/WebCell.tsx#L44-L55
但还需要类似 Next.js 这样的开发框架来输出符合新标准的 HTML 代码。