本文介绍了迁移Polymer项目.5到1.0错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图将我的项目从聚合物.5迁移到聚合物1.0。

我已安装新版本的聚合物库,铁元素&纸元素。
但是我收到以下错误:

此页面没有任何代码:

另外,我注意到目录结构对于核心保持不变元素,它没有改变为iron / neon元素。



所以我的代码使用相同的行来导入htmls。例如:



< link rel =importhref =〜/ Scripts / Polymer / core-animated-pages / transitions / slide-from-right.html>

另请查看附件截图:

解决方案

目录结构可能相同,但目前的文件nside 不同 - 重构/分割为多个文件。由于0.5和1.0不兼容,请确保您更新了代码。这个改变是一个很大的改变,它不仅仅是更新你的库。



查看他们的关于您将必须做出的更改。你可能需要改变很多。您使用的功能可能会被弃用,因此您将不得不使用较新的替代方法。 Polymer作者创建了一个名为的工具来帮助迁移,因此请检查一下。

I am trying to migrate my project from polymer .5 to polymer 1.0.

I have installed new version of polymer library, iron element & paper element.But I am getting following error:

This page does not have any code like:

Also, I have noticed that directory structure remains same for core elements. It did not changed to iron/ neon elements.

So my code uses the same line to import htmls. Eg:

<link rel="import" href="~/Scripts/Polymer/core-animated-pages/transitions/slide-from-right.html">

Also Please check screen shot attached:

解决方案

The directory structure maybe same but files present inside are different - refactored/split into multiple files. Since 0.5 and 1.0 are not compatible make sure you update your code too. The change is a big one and it is not simple as just updating your library.

Check their migration guide on changes you would have to make. You may have to change quite a bit. Features that you use could be deprecated, so you will have to use newer alternative. The Polymer authors have created a tool called polyup to assist in migration, so check that out.

这篇关于迁移Polymer项目.5到1.0错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-18 08:47