I am having trouble with ember-cli 0.0.28. All my initializers are failing to load. I am getting the following error.
Uncaught ReferenceError: module is not defined
The error is thrown for every jshit.js file that is created for each initializer.
Example:
define("fp-mobile/initializers/authentication.jshint",
[],
function() {
"use strict";
### This is the line that is blowing up.
module('JSHint - fp-mobile/initializers');
### Uncaught ReferenceError: module is not defined
test('fp-mobile/initializers/authentication.js should pass jshint', function() {
ok(true, 'fp-mobile/initializers/authentication.js should pass jshint.');
});
});//# sourceURL=fp-mobile/initializers/authentication.jshint.js
This started after upgrading from ember-cli 27 to ember-cli 0.0.28-master-cbd7c7c264.
Anyone have an idea of what might be causing this. Should I open a bug?
I fixed the problem by adding .es6 extension to initializer files
Change:
fp-mobile/initializers/authentication.js
To:
fp-mobile/initializers/authentication.js.es6
I think I will file a bug.
EDIT This doesn't really fix the issue, it just removes the initializer from the build. Something is still going on with the jshint implementation.
Working from ember-cli master and reverting broccoli-JSHint to v0.4.0 fixes the issue.
https://github.com/stefanpenner/ember-cli/issues/782
EDIT
Issue resolved.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With