question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error integration with Ionic2

See original GitHub issue

I am using ng2d3 with ionic2. It works very well when we compile it locally, but if I make a build for Android it retrieves the following error:

[16:36:11] copy finished in 110 ms [16:36:13] Error: Unexpected value ‘NG2D3Module’ imported by the module ‘AppModule’ [16:36:13] ngc failed [16:36:13] ionic-app-script task: “build” [16:36:13] Error: Error

I am using the following config:

{
  "name": "ionic-prototype",
  "author": "blabla",
  "homepage": "http://www.blabla.com/",
  "private": true,
  "scripts": {
    "build": "ionic-app-scripts build",
    "watch": "ionic-app-scripts watch",
    "serve:before": "watch",
    "emulate:before": "build",
    "deploy:before": "build",
    "build:before": "build",
    "run:before": "build"
  },
  "dependencies": {
    "@angular/common": "^2.2.3",
    "@angular/compiler": "^2.2.3",
    "@angular/compiler-cli": "^2.2.3",
    "@angular/core": "^2.2.3",
    "@angular/forms": "^2.2.3",
    "@angular/http": "^2.2.3",
    "@angular/platform-browser": "^2.2.3",
    "@angular/platform-browser-dynamic": "^2.2.3",
    "@angular/platform-server": "^2.2.3",
    "@ionic/storage": "1.1.6",
    "d3": "^4.4.0",
    "ionic-angular": "2.0.0-rc.3",
    "ionic-native": "^2.2.7",
    "ionicons": "3.0.0",
    "lodash": "^4.16.6",
    "moment": "^2.17.0",
    "ng2d3": "^1.6.2",
    "rxjs": "5.0.0-beta.12",
    "zone.js": "^0.7.2"
  },
  "devDependencies": {
    "@ionic/app-scripts": "0.0.46",
    "typescript": "^2.1.1"
  },
  "description": "ionic-prototype: An Ionic project",
  "cordovaPlugins": [
    "cordova-plugin-device",
    "cordova-plugin-console",
    "cordova-plugin-whitelist",
    "cordova-plugin-splashscreen",
    "cordova-plugin-statusbar",
    "ionic-plugin-keyboard"
  ],
  "cordovaPlatforms": []
}

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:12 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
amcdnlcommented, Dec 5, 2016

W00t!

0reactions
ghostcommented, Dec 6, 2016

@amcdnl I am experience the same issue as @zeornelas when building. Ionic serve is working as expected.

Error:

[11:10:57]  ionic-app-scripts 0.0.45
[11:10:57]  build prod started ...
[11:10:57]  clean started ...
[11:10:57]  clean finished in 8 ms
[11:10:57]  copy started ...
[11:10:57]  ngc started ...
[11:10:57]  copy finished in 376 ms
[11:11:21]  Error: Error at
            C:/Users/nicjr/Documents/Personal/Hydrate.Me-0.0.3/.tmp/node_modules/ng2d3/release/gauge/gauge.component.ngf
actory.ts:209:32
[11:11:21]  Module ''*'' has no exported member 'Wrapper_ChartComponent'.
[11:11:21]  ngc failed
[11:11:21]  ionic-app-script task: "build"
[11:11:21]  Error: Error

npm ERR! Windows_NT 10.0.14393
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run
" "build"
npm ERR! node v7.0.0
npm ERR! npm  v3.10.8
npm ERR! code ELIFECYCLE
npm ERR! Hydrate.Me@ build: `ionic-app-scripts build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the Hydrate.Me@ build script 'ionic-app-scripts build'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the Hydrate.Me package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     ionic-app-scripts build
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs Hydrate.Me
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls Hydrate.Me
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR!     C:\Users\nicjr\Documents\Personal\Hydrate.Me-0.0.3\npm-debug.log

Environment:

{
  "name": "Hydrate.Me",
  "author": "Nicholas Richardson",
  "homepage": "https://www.nicholas_richardson.com",
  "private": true,
  "scripts": {
    "build": "ionic-app-scripts build",
    "watch": "ionic-app-scripts watch",
    "serve:before": "watch",
    "emulate:before": "build",
    "deploy:before": "build",
    "build:before": "build",
    "run:before": "build"
  },
  "dependencies": {
    "@angular/common": "2.1.1",
    "@angular/compiler": "2.1.1",
    "@angular/compiler-cli": "2.1.1",
    "@angular/core": "2.1.1",
    "@angular/forms": "2.1.1",
    "@angular/http": "2.1.1",
    "@angular/platform-browser": "2.1.1",
    "@angular/platform-browser-dynamic": "2.1.1",
    "@angular/platform-server": "2.1.1",
    "@ionic/storage": "1.1.6",
    "core-js": "^2.4.1",
    "d3": "^4.3.0",
    "ionic-angular": "2.0.0-rc.3",
    "ionic-native": "2.2.3",
    "ionicons": "3.0.0",
    "moment": "^2.17.0",
    "ng2d3": "1.8.2",
    "rxjs": "^5.0.0-rc.3",
    "zone.js": "0.6.26"
  },
  "devDependencies": {
    "@ionic/app-scripts": "0.0.45",
    "typescript": "2.0.6"
  },
  "description": "Hydrate.Me3: A simple app to help you monitor your water intake.",
  "cordovaPlugins": [
    "cordova-plugin-device",
    "cordova-plugin-console",
    "cordova-plugin-whitelist",
    "cordova-plugin-splashscreen",
    "cordova-plugin-statusbar",
    "ionic-plugin-keyboard",
    "cordova-plugin-inappbrowser"
  ],
  "cordovaPlatforms": []
}
Read more comments on GitHub >

github_iconTop Results From Across the Web

Error when integrating Ionic2 Auth service - Stack Overflow
I'm trying to integrate Facebook login to my ionic 2 app. I was following the guide here and all is good until I...
Read more >
Build error: in razorpay integration - Ionic Forum
Build error: in razorpay integration · Ionic Framework ... i am using capacitor 3.4 in ionic 6,i am getting above error while taking...
Read more >
Ionic Error Logging with Sentry using Capacitor - YouTube
Learn to integrate Sentry.io in your Ionic application to setup error logging for Ionic and Capacitor apps! Learn Ionic faster with...
Read more >
Using Sentry - Error Monitoring with Ionic Angular Applications
In this tutorial, we will see how we can integrate Sentry — Error Monitoring with the Ionic Angular application. Why Error Monitoring is...
Read more >
Troubleshooting the Bitbucket Integration - Ionic
Topics in this Article: Errors during setup Commits not visible in Appflow Repo not selectable Errors during setup: The Bitbucket...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found