1
當serve
離子2應用程序出現錯誤。離子2:在應用程序app/ionic-anguler中尋找模塊不存在(模塊作爲目錄)
'looking for modules in app
app/ionic-anguler doesn't exist (module as directory)
resolve 'file' ionic-anguler in app
resolve file
app/ionic-anguler doesn't exist
app/ionic-anguler.js doesn't exist'
任何一個可以幫助我here.Thanks
home.js
import {Page, NavController} from 'ionic-angular';
import {Page2} from '../page2/page2';
@Page({
templateUrl: 'build/pages/home/home.html'
})
export class HomePage {
static get parameters(){
return [[NavController]];
}
constructor(nav){
this.nav = nav;
}
go_to_page_2(){
this.nav.push(Page2);
}
}
錯誤日誌
./app/pages/home/home.js
Module not found: Error: Cannot resolve module 'ionic-anguler' in /Users/kosala/Desktop/IonicProjects/test_three/app/app/pages/home
resolve module ionic-anguler in /Users/kosala/Desktop/IonicProjects/test_three/app/app/pages/home
looking for modules in app
app/ionic-anguler doesn't exist (module as directory)
resolve 'file' ionic-anguler in app
resolve file
app/ionic-anguler doesn't exist
app/ionic-anguler.js doesn't exist
looking for modules in /Users/kosala/Desktop/IonicProjects/test_three/app/node_modules
/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler doesn't exist (module as directory)
resolve 'file' ionic-anguler in /Users/kosala/Desktop/IonicProjects/test_three/app/node_modules
resolve file
/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler doesn't exist
/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler.js doesn't exist
[app/ionic-anguler]
[app/ionic-anguler]
[app/ionic-anguler.js]
[/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler]
[/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler]
[/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler.js]
@ ./app/pages/home/home.js 12:20-44,./app/pages/page2/page2.js
Module not found: Error: Cannot resolve module 'ionic-anguler' in /Users/kosala/Desktop/IonicProjects/test_three/app/app/pages/page2
resolve module ionic-anguler in /Users/kosala/Desktop/IonicProjects/test_three/app/app/pages/page2
looking for modules in app
resolve 'file' ionic-anguler in app
resolve file
app/ionic-anguler doesn't exist
app/ionic-anguler.js doesn't exist
app/ionic-anguler doesn't exist (module as directory)
looking for modules in /Users/kosala/Desktop/IonicProjects/test_three/app/node_modules
resolve 'file' ionic-anguler in /Users/kosala/Desktop/IonicProjects/test_three/app/node_modules
resolve file
/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler doesn't exist
/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler.js doesn't exist
/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler doesn't exist (module as directory)
[app/ionic-anguler]
[app/ionic-anguler.js]
[app/ionic-anguler]
[/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler]
[/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler.js]
[/Users/kosala/Desktop/IonicProjects/test_three/app/node_modules/ionic-anguler]
@ ./app/pages/page2/page2.js 10:20-44 (CLI v2.0.0-beta.19)
即時通訊仍然會出現error.update問題,並附有新的錯誤日誌 – kosala
它仍然會說「離子Angul ** E ** r」,而不是「ionic-angul ** A ** r」 –