npm test => Error in config file! #1063

Closed
opened 2025-08-09 17:18:44 +00:00 by fergalmoran · 0 comments
Owner

Originally created by @ManuelDeLeon on 1/31/2017

So the new Angular generator (v0.8.0) now exports a function in the webpack config files, yet the karma config wasn't updated and thus you get require('../../webpack.config.js').filter is not a function when you try to run the tests.

A simple fix is to run the config: require('../../webpack.config.js')().filter

*Originally created by @ManuelDeLeon on 1/31/2017* So the new Angular generator (v0.8.0) now exports a function in the webpack config files, yet the karma config wasn't updated and thus you get `require('../../webpack.config.js').filter` is not a function when you try to run the tests. A simple fix is to run the config: `require('../../webpack.config.js')().filter`
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/JavaScriptServices#1063
No description provided.