在已经具有Polymer 1.5组件的项目中使用Polymer 2.0webcomponents
编写时出现问题。
有一个错误:
Uncaught DOMException: Failed to execute 'registerElement' on 'Document': Registration failed for type 'dom-module'. A type with that name is already registered.
据我了解,错误是由页面上两个版本的 Polymer 之间的冲突引起的。(两个版本都试图创建一个全局对象 Polymer)
有没有办法允许在同一页面上使用两个不同版本的聚合物?(类似于jQuery.noConflict()
)