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 using Webpack

See original GitHub issue

I’m getting a strange error. It also could be because I’m a bit new to ES6 + true modules.

Argument 'module' is not a function, got Object

Does this package work out of the box with Webpack or do I need to do something different?

Issue Analytics

  • State:open
  • Created 7 years ago
  • Reactions:1
  • Comments:11

github_iconTop GitHub Comments

7reactions
mcblumcommented, Nov 8, 2016

@ArthurianX try: import ngStorage from 'ngstorage'; angular.module('app', [ ngStorage.name ]);

1reaction
AldoMXcommented, Jan 3, 2017

This is a workaround:

const angular = require('angular');
const ngStorage = (() => 'ngStorage')(require('ngstorage'));
angular.module('app', [ngStorage]);
Read more comments on GitHub >

github_iconTop Results From Across the Web

How I solved and debugged my Webpack issue through trial ...
What can you do if you have a webpack issue? · Search in the GitHub issues similar to yours. · Try to check...
Read more >
How to Prevent Webpack Error after npm Install?
It seems to work now with webpack 2.1.0-beta.22 , but you got another error. This error happened because extract-text-webpack-plugin is not of the...
Read more >
Webpack 5 errors | ImmutableX Documentation
The reason for this error is that create-react-app uses a version of webpack greater than 5, which, unlike versions < 5, does not...
Read more >
"0:0 error Module Error [...]" when using with webpack #1909
Hello, Using this in my package.json file : [. ... It seems there is a bug when using webpack --mode development (even in...
Read more >
Development | webpack
When webpack bundles your source code, it can become difficult to track down errors and warnings to their original location. For example, if...
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