2016-12-20 6 views
0

私はurigo/angular2-meteor-baseでプレイし始めました。公式のチュートリアルに続いて、フロントエンドCSSフレームワークをテストしたいと思っています。私はpoetic:materialize-scssを選択したが、scssファイルをインポートする際に問題がある。公式ドキュメントからAngular2-Meteorとmaterialize-scss

インストール:プロジェクトフォルダ内meteorを実行した後

@import "{poetic:materialize-scss}/sass/materialize.scss"; 

と、私は次のエラーを取得する:

meteor add fourseven:scss 
meteor add poetic:materialize-scss 

はその後、クライアント/スタイル/ main.scssでSCSSをインポート:

Errors prevented startup: 

While determining active plugins: 
error: conflict: two packages included in the app (fourseven:scss and angular2-compilers) are both trying to handle *.scss 
error: conflict: two packages included in the app (fourseven:scss and angular2-compilers) are both trying to handle *.sass 

だから私はfourseven:scssを削除しようとしました。再びmeteorを実行している:

Errors prevented startup: 

While processing files with angular2-compilers (for target web.browser): 
/client/styles/main.scss: Scss compiler error: 
File to import {poetic:materialize-scss}/sass/materialize.scss not found in file: 
/home/vagrant/Projects/NgMeteor/{}/client/styles/main.scss 

これは、インストールされたパッケージのリストです:

angular2-compilers   0.6.6 
autopublish    1.0.7 
dispatch:mocha-phantomjs 0.1.9 
es5-shim     4.6.15 
hwillson:stub-collections 1.0.3 
insecure     1.0.7 
meteor-base    1.0.4 
mobile-experience   1.0.4 
mongo      1.1.14 
poetic:materialize-scss 1.97.6_1 
practicalmeteor:mocha  2.4.5_6 
reactive-var    1.0.11 
shell-server    0.2.1 
standard-minifier-css  1.3.2 
standard-minifier-js  1.2.1 
tracker     1.1.1 
xolvio:cleaner    0.3.1 

ない私は右の場所からSCSSファイルをインポートしていた場合に確認してください...誰もが同じ問題を抱えていますか?

答えて

1

流星パッケージscssのインストール方法はわかりませんが、npmパッケージをインクルードする方法を知っていますので、npm経由でインストールするだけのソリューションとして、npmパッケージをインストールしてから、それをインクルードしてください。ここにはhttps://github.com/Dogfalo/materialize/blob/master/sass/materialize.scssに位置しているようです。 @import "{} /node_modules/materialize/sass/materialize.scss"; また、https://github.com/angular/material2について知りたいですか?代わりにそれを使用することをお勧めしたいと思います。

+0

ありがとう@bergben、私はmaterial2をチェックします! – Luciano

関連する問題