Skip to content
This repository has been archived by the owner on Feb 18, 2025. It is now read-only.

Make importable with webpack 2 #23

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

christiaanwesterbeek
Copy link

With Webpack 2 and Angular 1.x with this

import angularSimpleLogger from 'angular-simple-logger'

angular.module('app', [angularSimpleLogger])

Is throwing this angular error when it spins up

app.bundle.js:55447 Uncaught Error: [$injector:modulerr] Failed to instantiate module app due to:
Error: [$injector:modulerr] Failed to instantiate module {} due to:
Error: [ng:areq] Argument 'module' is not a function, got Object
http://errors.angularjs.org/1.5.9/ng/areq?p0=module&p1=not%20a%20function%2C%20got%20Object

I'm not sure why, but the change in this PR fixes that. Not sure if it introduces other problems.

@nmccready
Copy link
Owner

Can you update the Travis issues? First try updating mode and some of the dependencies. I will merge this if we can get this to pass.

@christiaanwesterbeek
Copy link
Author

christiaanwesterbeek commented Jul 22, 2017

I'm sorry @nmccready , but that will take me too much time considering my agenda. If nobody is interested in fixing the Travis issues and it doesn't get merged, I'll understand and I will use a local wrapper in that case so to fix the webpack importability.

@nmccready
Copy link
Owner

nmccready commented Jul 22, 2017 via email

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants