无法集成ng2材料和角度材料

时间:2016-06-10 19:18:28

标签: angular angular-material

我一直在使用angular2-material作为angular2中的材质设计组件。它解决了我的大多数用例,但是我需要的一些组件在库中缺失(模态,子菜单等)。 我发现ng2-material并且一直试图同时使用它们。

导入ng2-material后,我遇到了npm问题而无法解决这些问题。

这是我的package.json

的相关部分
...
"@angular/common": "2.0.0-rc.1",
"@angular/compiler": "2.0.0-rc.1",
"@angular/core": "2.0.0-rc.1",
"@angular/http": "2.0.0-rc.1",
"@angular/platform-browser": "2.0.0-rc.1",
"@angular/platform-browser-dynamic": "2.0.0-rc.1",
"@angular/router-deprecated": "2.0.0-rc.1",
"@angular2-material/button": "^2.0.0-alpha.5-2",
"@angular2-material/core": "2.0.0-alpha.5-2",
"@angular2-material/input": "^2.0.0-alpha.5-2",
"@angular2-material/list": "^2.0.0-alpha.5-2",
"@angular2-material/sidenav": "^2.0.0-alpha.5-2",
"@angular2-material/toolbar": "^2.0.0-alpha.5-2",
"@angular2-material/icon": "^2.0.0-alpha.5-2",
"@angular2-material/slide-toggle": "^2.0.0-alpha.5-2",
"ng2-material":"0.4.1"
...

这是我遇到的依赖性错误

app@0.0.0 /path/to/my/project/ui-angular
+-- UNMET PEER DEPENDENCY @angular/router@2.0.0-rc.1
+-- UNMET PEER DEPENDENCY @angular2-material/checkbox@^2.0.0-alpha.4
+-- UNMET PEER DEPENDENCY @angular2-material/progress-bar@^2.0.0-alpha.4
+-- UNMET PEER DEPENDENCY @angular2-material/progress-circle@^2.0.0-alpha.4
+-- UNMET PEER DEPENDENCY @angular2-material/radio@^2.0.0-alpha.4
+-- UNMET PEER DEPENDENCY es6-promise@>=3.0.2
`-- ng2-material@0.4.1 


npm WARN optional Skipping failed optional dependency /chokidar/fsevents:
npm WARN notsup Not compatible with your operating system or architecture: fsevents@1.0.12
npm WARN enoent ENOENT: no such file or directory, open '/path/to/my/project/ui-angular/node_modules/material-design-icons/package.json'
npm WARN ng2-material@0.4.1 requires a peer of @angular/router@2.0.0-rc.1 but none was installed.
npm WARN ng2-material@0.4.1 requires a peer of @angular2-material/checkbox@^2.0.0-alpha.4 but none was installed.
npm WARN ng2-material@0.4.1 requires a peer of @angular2-material/progress-bar@^2.0.0-alpha.4 but none was installed.
npm WARN ng2-material@0.4.1 requires a peer of @angular2-material/progress-circle@^2.0.0-alpha.4 but none was installed.
npm WARN ng2-material@0.4.1 requires a peer of @angular2-material/radio@^2.0.0-alpha.4 but none was installed.
npm WARN ng2-material@0.4.1 requires a peer of es6-promise@>=3.0.2 but none was installed.

甚至可以结合使用2个库吗?

0 个答案:

没有答案