Having Node module issue after upgrade to native script 8.1.5

Viewed 305

I have upgraded my Native script Project which was running fine on previous version. After upgraded to 8.1.5, Having node modules error.

My package.json

{
  "description": "Order Next Application",
  "license": "SEE LICENSE IN <your-license-filename>",
  "repository": "<fill-your-repository-here>",
  "dependencies": {
    "@angular-devkit/build-angular": "^13.1.2",
    "@angular/animations": "^13.1.1",
    "@angular/cli": "^13.1.2",
    "@angular/common": "^13.1.1",
    "@angular/compiler": "^13.1.1",
    "@angular/core": "^13.1.1",
    "@angular/forms": "^13.1.1",
    "@angular/http": "^7.2.16",
    "@angular/platform-browser": "^13.1.1",
    "@angular/platform-browser-dynamic": "^13.1.1",
    "@angular/router": "^13.1.1",
    "@nativescript/angular": "^13.0.1",
    "@nativescript/core": "^8.1.5",
    "@nativescript/firebase": "^11.1.3",
    "@ngtools/webpack": "^13.1.2",
    "@nstudio/nativescript-checkbox": "^2.0.4",
    "@nstudio/nativescript-loading-indicator": "^3.0.1",
    "@types/node": "^17.0.9",
    "font-awesome": "^4.7.0",
    "nativescript-accordion": "^5.0.4",
    "nativescript-drop-down": "^5.0.6",
    "nativescript-feedback": "^2.0.0",
    "nativescript-geolocation": "^5.1.0",
    "nativescript-iqkeyboardmanager": "^1.5.1",
    "nativescript-phone": "^1.4.0",
    "nativescript-ratings": "^1.0.1",
    "nativescript-ripple": "^4.0.1",
    "nativescript-screen-orientation": "^1.0.0",
    "nativescript-theme-core": "~1.0.4",
    "nativescript-ui-listview": "^10.0.2",
    "nativescript-youtubeplayer": "^3.0.1",
    "reflect-metadata": "~0.1.10",
    "rxjs": "~7.3.0",
    "zone.js": "~0.11.4"
  },
  "devDependencies": {
    "@angular/compiler-cli": "^13.1.1",
    "@nativescript/android": "8.1.1",
    "@nativescript/schematics": "~0.4.0",
    "@nativescript/types": "^8.1.1",
    "@nativescript/webpack": "^5.0.4",
    "typescript": "^4.5.4"
  },
  "readme": "NativeScript Application",
  "main": "./src/main.ts"
}

I'm getting following errors form the dependencies,

Click here to see error image

Kindly help me with the solution.
1 Answers

You didn't mention which version of nativescript you upgraded from, but when migrating your nativescript project you have to manually modify your code according to this nativescript migration guide to NS6, migration guide to NS7 and migration guide to NS8.

Make sure to follow all the steps, apply the required changes to your code, including running ns migrate.

However, in the example you provided, it looks that you didn't update the imports to match Angular 13 and Nativescript 8. Change your imports to the following and you should be ok:

import { View, ObservableArray, CoercibleProperty, EventData, Property } from '@nativescript/core';
import { BaseValueAccessor } from "@nativescript/angular";
Related