When using any Ionic3 app service
import * as jsnx from 'jsnetworkx';
The output error message is:
Uncaught (in promise): Error: Cannot find module "lodash/lang/isPlainObject" Error: Cannot find module "lodash/lang/isPlainObject" at webpackMissingModule
I attempted to declare it in this manner:
import jsnx = require('jsnetworkx');
but encountered the following error:
Uncaught (in promise): ReferenceError: jsnx is not defined ReferenceError: jsnx is not defined at
Both packages are currently installed:
...,
"jsnetworkx": "^0.3.4",
"lodash": "^4.17.4",
...
If anyone knows how to resolve this issue in Angular 4 or Ionic, please share your insights.
The library functions correctly when used with Node.js.