I can not run my app with ionic


I am new to the forum and in the ionic world, I started to get interested in the development of apps and it seemed like a good ionic option, make the installations as indicated on your page and when you give ionic serve it appears the next.

[ng] Could not find module "@angular-devkit/build-angular" from "C:\Users\nikce\documents\project\myapp\myapp".
[ng] Error: Could not find module "@angular-devkit/build-angular" from "C:\Users\nikce\documents\project\myapp\myapp".
[ng]     at Object.resolve (C:\Users\nikce\AppData\Roaming\npm\node_modules\@angular\cli\node_modules\@angular-devkit\core\node\resolve.js:141:11)
[ng]     at Observable.rxjs_1.Observable [as _subscribe] (C:\Users\nikce\AppData\Roaming\npm\node_modules\@angular\cli\node_modules\@angular-devkit\architect\src\architect.js:132:40)
[ng]     at Observable._trySubscribe (C:\Users\nikce\AppData\Roaming\npm\node_modules\@angular\cli\node_modules\rxjs\internal\Observable.js:43:25)
[ng]     at Observable.subscribe (C:\Users\nikce\AppData\Roaming\npm\node_modules\@angular\cli\node_modules\rxjs\internal\Observable.js:29:22)
[ng]     at DoOperator.call (C:\Users\nikce\AppData\Roaming\npm\node_modules\@angular\cli\node_modules\rxjs\internal\operators\tap.js:29:23)

[ng]     at Observable.subscribe (C:\Users\nikce\AppData\Roaming\npm\node_modules\@angular\cli\node_modules\rxjs\internal\Observable.js:24:22)
[ng]     at C:\Users\nikce\AppData\Roaming\npm\node_modules\@angular\cli\node_modules\rxjs\internal\util\subscribeTo.js:22:31
[ng]     at Object.subscribeToResult (C:\Users\nikce\AppData\Roaming\npm\node_modules\@angular\cli\node_modules\rxjs\internal\util\subscribeToResult.js:7:45)
[ng]     at MergeMapSubscriber._innerSub (C:\Users\nikce\AppData\Roaming\npm\node_modules\@angular\cli\node_modules\rxjs\internal\operators\mergeMap.js:75:38)
[ng]     at MergeMapSubscriber._tryNext (C:\Users\nikce\AppData\Roaming\npm\node_modules\@angular\cli\node_modules\rxjs\internal\operators\mergeMap.js:72:14)

[ERROR] ng has unexpectedly closed (exit code 1).

Try to give a solution but I can not give in the key with the problem of Angular but I could not. I hope you can help me.


   ionic (Ionic CLI)             : 4.2.1 (C:\Users\nikce\AppData\Roaming\npm\node_modules\ionic)
   Ionic Framework               : @ionic/angular 4.0.0-beta.12
   @angular-devkit/build-angular : not installed
   @angular-devkit/schematics    : not installed
   @angular/cli                  : not installed
   @ionic/angular-toolkit        : not installed


   cordova (Cordova CLI) : 8.1.2 ([email protected])
   Cordova Platforms     : not available
   Cordova Plugins       : not available


   NodeJS : v8.12.0 (C:\Program Files\nodejs\node.exe)
   npm    : 6.4.1
   OS     : Windows 10


I just entered the Angular page and installed the CLI and built a new app from ionic using ionic start appName template --type=angular and also the ionic start appName template command but the error persisted.

Angular CLI: 6.2.5
Node: 8.12.0
OS: win32 x64

Package                      Version
@angular-devkit/architect    0.8.5
@angular-devkit/core         0.8.5
@angular-devkit/schematics   0.8.5
@schematics/angular          0.8.5
@schematics/update           0.8.5
rxjs                         6.2.2
typescript                   2.9.2
asked by Veljko Nikcevich 13.10.2018 в 17:14

1 answer


Note: The following is a comment for people entering this new world of hybrid applications.

To enter a command such as ionic serve in your console, you must take into account an important parameter:

  • First you must build your application with the ionic start command in the folder of your preference (where you store your applications) or you can use ionic start miApp tabs to create a template of type tabs .
  • After you have the complete package you can start running the cordova ionic serve service which will later open a localhost:8100 window in your browser.
  • Problematic

    You must install @angular-devkit/build-angular , which is linked in new versions as a development dependency. Angular 6.X.X.

    So try the following command to perform the respective installation of the dependency:


    npm install --save-dev @angular-devkit/build-angular


    yarn add @angular-devkit/build-angular --dev

    And if this does not work I recommend that you move to your folder, where is your application and run the following command with npm :

    npm install --save @angular-devkit/build-angular

    You try and tell me if it solves your problem

    answered by 13.10.2018 в 17:37