Home > database >  Error: Package "@ionic/angular-toolkit" has no builders defined
Error: Package "@ionic/angular-toolkit" has no builders defined

Time:03-16

[error] Error: Package "@ionic/angular-toolkit" has no builders defined.}
    at WorkspaceNodeModulesArchitectHost.resolveBuilder (C:\Users\Lenovo\Documents\krishikhoj\krishikhoj-ionic-app\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js:121:19)
    at RunCommand.runSingleTarget (C:\Users\Lenovo\Documents\krishikhoj\krishikhoj-ionic-app\node_modules\@angular\cli\models\architect-command.js:245:53)
    at async RunCommand.runArchitectTarget (C:\Users\Lenovo\Documents\krishikhoj\krishikhoj-ionic-app\node_modules\@angular\cli\models\architect-command.js:295:24)
    at async RunCommand.validateAndRun (C:\Users\Lenovo\Documents\krishikhoj\krishikhoj-ionic-app\node_modules\@angular\cli\models\command.js:136:22)
    at async runCommand (C:\Users\Lenovo\Documents\krishikhoj\krishikhoj-ionic-app\node_modules\@angular\cli\models\command-runner.js:224:24)
    at async default_1 (C:\Users\Lenovo\Documents\krishikhoj\krishikhoj-ionic-app\node_modules\@angular\cli\lib\cli\index.js:70:31)

CodePudding user response:

I kicked out the issue by using this solution.

  1. run sudo npm install -g @ionic/cli@latest
    to install latest ionic package and run
    npm outdated
    to get outdated packages.
  2. run npm install package_name@latest --force (replace 'package_name' with the outdated package name) for every package shown in outdated package list
  3. Ignore any warning during update.


    TIP:Updating all the outdated packages saves you from app's low performance and improves security

CodePudding user response:

For future references: here an explanation and how to fix it. I also needed to edit the angular.json to change the cordova builder.

  • Related