Adding custom npm package to webpack.config.vendor.js doesn't work
Hello,
I'm trying to integrate a 3rd party angular components, and they have a npm package they ship.
Following their instructions, I have the following in the package.json:
"wijmo": "../3rdParty/wijmo/wijmo-system-min"
This will then create a wijmo folder inside of the node_modules.
Then I further go into webpack.config.vendor.js, and add the following to the vendor section:
var sharedConfig = {
entry: {
vendor: [
'wijmo'
]
},
}
When I do that and run:
webpack --config webpack.config.vendor.js
I get the following error:
ERROR in dll vendor
Module not found: Error: Cannot resolve module 'wijmo' in
What am I doing wrong? Any help would be greatly appreciated.
Thanks!
I was able to resolve this by changing my webpack.config.vendor.js to the following:
entry: {
vendor: [
'wijmo/wijmo.js',
'wijmo/wijmo.grid.js',
'wijmo/wijmo.angular2.core.js',
'wijmo/wijmo.angular2.grid.js',
'wijmo/styles/wijmo.min.css'
]
},
Thank you for documenting this. I just happened to run across this while searching for a solution. Would be nice is Wijmo had this documented on their website.