之间有什么区别吗? Material Web 组件 ( link ) 和 Material 组件网 (link)?
Material Web Components 没有太多解释
Built on top of the Material Components Web project and LitElement, the Material Web Components enable a reliable development workflow to build beautiful and functional web projects.
而 Material Components Web 是
Material Components for the web (MDC Web) helps developers execute Material Design. Developed by a core team of engineers and UX designers at Google, these components enable a reliable development workflow to build beautiful and functional web projects.
它只是在 LitElement 中使用 Web 组件重新实现所有 MDC 组件吗?
目前关于 Material Web Components 的文档非常稀少,因此很难在测试应用程序中使用它们进行比较。
顺便说一句,这个命名是 可怕 ,希望他们在预发布期间更改名称。
最佳答案
Material 组件 Web 组件 项目 ( link ) 建立在 之上 Material 组件网项目 ( link ) 创建 自定义元素 (link)。
使用 时 Material 组件网您必须在您的网页中包含项目提供的 CSS 和 javascript。
Material 组件 Web 组件 定义 新的 HTML 标签 使用自定义元素规范。此类标签的示例是 <mwc-drawer>
, <mwc-icon>
.
新标签是自定义元素并且是完全独立的。 CSS 和 javascript 是组件的一部分,与页面的其余部分隔离。
关于javascript - Material Web 组件与 Material 组件 Web,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57752189/