2016-04-03 60 views
0

我正在學習ionic2。我認爲示例應用程序是一個很好的起點,但不幸的是,我無法得到它的工作。它抱怨丟失module.Please看到輸出:離子2樣本會議應用程序無法找到babelify模塊

[email protected]:~/pj/ionic-conference-app$ ionic serve 

Running 'serve:before' gulp task before serve 
[08:53:57] Starting 'sass'... 
[08:53:57] Starting 'html'... 
[08:53:57] Starting 'fonts'... 
[08:53:57] Starting 'scripts'... 
[08:53:57] Finished 'scripts' after 63 ms 
[08:53:57] Finished 'html' after 115 ms 
[08:53:57] Finished 'fonts' after 114 ms 
[08:53:58] Finished 'sass' after 888 ms 
[08:53:58] Starting 'watch'... 
✗ Caught exception: 
Error: Cannot find module 'babelify' from '/home/lola/pj/ionic-conference-app' 
at /home/lola/pj/ionic-conference-app/node_modules/ionic-gulp-browserify-es2015/node_modules/browserify/node_modules/resolve/lib/async.js:46:17 
at process (/home/lola/pj/ionic-conference-app/node_modules/ionic-gulp-browserify-es2015/node_modules/browserify/node_modules/resolve/lib/async.js:173:43) 
at ondir (/home/lola/pj/ionic-conference-app/node_modules/ionic-gulp-browserify-es2015/node_modules/browserify/node_modules/resolve/lib/async.js:188:17) 
at load (/home/lola/pj/ionic-conference-app/node_modules/ionic-gulp-browserify-es2015/node_modules/browserify/node_modules/resolve/lib/async.js:69:43) 
at onex (/home/lola/pj/ionic-conference-app/node_modules/ionic-gulp-browserify-es2015/node_modules/browserify/node_modules/resolve/lib/async.js:92:31) 
at /home/lola/pj/ionic-conference-app/node_modules/ionic-gulp-browserify-es2015/node_modules/browserify/node_modules/resolve/lib/async.js:22:47 
at FSReqWrap.oncomplete (fs.js:82:15) 

Mind letting us know? https://github.com/driftyco/ionic-cli/issues 

$ionic info 

Your system information: 

Cordova CLI: 6.1.1 
Ionic Version: 2.0.0-beta.3 
Ionic CLI Version: 2.0.0-beta.22 
Ionic App Lib Version: 2.0.0-beta.12 
OS: 
Node Version: v4.4.2 

任何人都可以幫助我嗎?

+0

您是否運行過'npm install' –

回答

0

很可能,您需要更新包含babelify依賴關係的NPM。通過運行npm -v來檢查您的NPM版本,它應該是v3.x.運行sudo npm install -g npm更新npm。你應該很好走。

+0

謝謝Michael。 – lola

+0

我相信沒有必要在全球安裝項目包,本地就足夠了 –

0

只是npm install在項目的根爲我工作。

相關問題