Production error in angular


#1

hey everyone i am using nativescript angular and I have an error while make production app.
this is a error messaage log

const config = ngtools_api_1.readConfiguration(this._tsConfigPath);
^
TypeError: ngtools_api_1.readConfiguration is not a function
at NativeScriptAngularCompilerPlugin._setupOptions (D:\projects\troutBird\production-mobile-app\mobile-app\node_modules@ngtools\webpack\src\angular_compiler_plugin.js:88:38)
at new AngularCompilerPlugin (D:\projects\troutBird\production-mobile-app\mobile-app\node_modules@ngtools\webpack\src\angular_compiler_plugin.js:43:14)
at new NativeScriptAngularCompilerPlugin (D:\projects\troutBird\production-mobile-app\mobile-app\node_modules\nativescript-dev-webpack\plugins\NativeScriptAngularCompilerPlugin.ts:36:9)
at module.exports.env (D:\projects\troutBird\production-mobile-app\mobile-app\webpack.config.js:115:13)
at handleFunction (D:\projects\troutBird\production-mobile-app\mobile-app\node_modules\webpack\lib\prepareOptions.js:26:13)
at prepareOptions (D:\projects\troutBird\production-mobile-app\mobile-app\node_modules\webpack\lib\prepareOptions.js:11:13)
at requireConfig (D:\projects\troutBird\production-mobile-app\mobile-app\node_modules\webpack\bin\convert-argv.js:98:14)
at D:\projects\troutBird\production-mobile-app\mobile-app\node_modules\webpack\bin\convert-argv.js:104:17
at Array.forEach ()
at module.exports (D:\projects\troutBird\production-mobile-app\mobile-app\node_modules\webpack\bin\convert-argv.js:102:15)
at yargs.parse (D:\projects\troutBird\production-mobile-app\mobile-app\node_modules\webpack\bin\webpack.js:171:41)
at Object.Yargs.self.parse (D:\projects\troutBird\production-mobile-app\mobile-app\node_modules\yargs\yargs.js:533:18)
at Object. (D:\projects\troutBird\production-mobile-app\mobile-app\node_modules\webpack\bin\webpack.js:152:7)
at Module._compile (module.js:635:30)
at Object.Module._extensions…js (module.js:646:10)
at Module.load (module.js:554:32)
Unable to apply changes on device: emulator-5554. Error is: Executing webpack failed with exit code 1…
Executing after-watch hook from D:\projects\troutBird\production-mobile-app\mobile-app\hooks\after-watch\nativescript-dev-typescript.js
-------------------------------------
My package.jso is


________________
		{
  "name": "tradelive",
  "version": "1.0.0",
  "description": "NativeScript Application",
  "license": "SEE LICENSE IN <your-license-filename>",
  "readme": "NativeScript Application",
  "repository": "<fill-your-repository-here>",
  "nativescript": {
    "id": "org.nativescript.tradelivemobile",
    "tns-android": {
      "version": "3.4.0"
    }
  },
  "scripts": {
    "tslint": "tslint -p tsconfig.json"
  },
  "dependencies": {
    "@angular/animations": "~4.4.1",
    "@angular/common": "~4.4.1",
    "@angular/compiler": "~4.4.1",
    "@angular/core": "~4.4.1",
    "@angular/forms": "~4.4.1",
    "@angular/http": "~4.4.1",
    "@angular/platform-browser": "~4.4.1",
    "@angular/router": "~4.4.1",
    "@types/lodash": "^4.14.91",
    "@wwwalkerrun/nativescript-ngx-magic": "^2.0.4",
    "angular2-jwt": "^0.2.3",
    "js-data": "^3.0.1",
    "js-data-http": "^3.0.0",
    "lodash": "^4.17.4",
    "nativescript-angular": "^5.0.0",
    "nativescript-badge-button": "^0.1.2",
    "nativescript-barcodescanner": "^2.7.3",
    "nativescript-bottombar": "^3.0.7",
    "nativescript-checkbox": "^3.0.3",
    "nativescript-exit": "^1.0.1",
    "nativescript-feedback": "^1.1.0",
    "nativescript-floatingactionbutton": "^4.1.3",
    "nativescript-loading-indicator": "^2.4.0",
    "nativescript-localstorage": "^1.1.5",
    "nativescript-material-icons": "^1.0.3",
    "nativescript-ng-shadow": "^2.1.0",
    "nativescript-ng2-fonticon": "^1.3.4",
    "nativescript-ngx-fonticon": "^4.0.0",
    "nativescript-permissions": "^1.2.3",
    "nativescript-pro-ui": "^3.4.1",
    "nativescript-ripple": "^2.0.0",
    "nativescript-snackbar": "^2.0.0",
    "nativescript-theme-core": "~1.0.2",
    "nativescript-toast": "^1.4.6",
    "reflect-metadata": "~0.1.8",
    "rxjs": "~5.4.2",
    "tns-core-modules": "^3.4.0",
    "zone.js": "~0.8.2"
  },
  "devDependencies": {
    "@angular/compiler-cli": "~4.4.1",
    "@ngtools/webpack": "~1.9.4",
    "@types/jasmine": "^2.8.2",
    "babel-traverse": "6.26.0",
    "babel-types": "6.26.0",
    "babylon": "6.18.0",
    "codelyzer": "^4.0.2",
    "copy-webpack-plugin": "~4.3.0",
    "css-loader": "~0.28.7",
    "extract-text-webpack-plugin": "~3.0.2",
    "lazy": "1.0.11",
    "nativescript-dev-typescript": "^0.6.0",
    "nativescript-dev-webpack": "^0.9.0",
    "nativescript-worker-loader": "~0.8.1",
    "raw-loader": "~0.5.1",
    "resolve-url-loader": "~2.2.1",
    "tslint": "^5.8.0",
    "typescript": "^2.4.2",
    "uglifyjs-webpack-plugin": "~1.1.6",
    "webpack": "~3.10.0",
    "webpack-bundle-analyzer": "^2.9.1",
    "webpack-sources": "~1.1.0"
  }
}
_______

tsconfig.json is


		
		{
    "compilerOptions": {
        "module": "commonjs",
        "target": "es6",
        "experimentalDecorators": true,
        "emitDecoratorMetadata": true,
        "noEmitHelpers": true,
        "noEmitOnError": true,
        "lib": [
            "es6",
            "dom",
            "es2015.iterable"
        ],
        "baseUrl": ".",
        "paths": {
            "*": [
                "./node_modules/tns-core-modules/*",
                "./node_modules/*"
            ]
        }
    },
    "exclude": [
        "node_modules",
        "platforms",
        "**/*.aot.ts"
    ]
}