Open an-rahulpandey opened 7 years ago
Moreover, if I just add the uncompressed js file in my scripts folder, I get the same JS Parse Error. However, if I add the minified file in my scripts folder, then it doesn't give any error.
I just published version 1.5.1 of the generator with updated wiredep
- it worked for me without issues to add angular-img-fallback - please try this latest version.
you should add this script via bower install angular-img-fallback --save
not manually.
I just reinstalled the generator and created a demo project, but still getting the same error.
snip
the output you posted is unrelated, it just showed all the installed npm modules. I edited that to keep this issue readable. which node.js version are you on?
Node version is 4.4.5.
try commenting out the uglify part in the vendor task in your generated gulpfile.js around line 193.
gulp.task('vendor', function() {
var vendorFiles = wiredep().js;
return gulp.src(vendorFiles)
.pipe(plugins.concat('vendor.js'))
//.pipe(plugins.if(build, plugins.uglify()))
.pipe(plugins.if(build, plugins.rev()))
.pipe(gulp.dest(targetDir))
.on('error', errorHandler);
});
Let's see if that helps, from your initial error message it looks like the error is connected to the uglification.
Yes, commenting out that line works.
how did you install that library? It works for me if I install it via bower. Maybe you added the already minified version manually and so the uglify job breaks?
I also installed it via bower bower install angular-img-fallback --save
you might try updating gulp-uglify in your package.json
Hi,
I am getting JS Parse error message after installing the angular module the https://github.com/dcohenb/angular-img-fallback
Library Versions -