You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
with css links it works fine, but with js is give me error:
TypeError: Parameter 'url' must be a string, not undefined
here is my code for js
gulp.task('copy-js', function() {
gulp.src('./src/*.html')
.pipe(ghtmlSrc())
// From this point, it's as if you'd used gulp.src() listing each of your
// javascript files that are in your html as <script src="..."></script>
.pipe(uglify())
.pipe(gulp.dest('./build/'));
});
The text was updated successfully, but these errors were encountered:
I've just come across this. It occurs with embedded scripts - eg google analytics. It's easy to workaround and even helps with best-practices - just place the script in a separate file and update the script element. But perhaps you should exclude script elements without a src attribute?
I also came across another issue with external scripts. If a script element has an external src, eg a file on a cdn, it silently fails. The output is empty but no error is produced. Again, I can work around this by downloading the script and saving it in a separate file. Perhaps you should exclude scripts whose src can't be resolved locally?
with css links it works fine, but with js is give me error:
TypeError: Parameter 'url' must be a string, not undefined
here is my code for js
gulp.task('copy-js', function() {
gulp.src('./src/*.html')
.pipe(ghtmlSrc())
// From this point, it's as if you'd used gulp.src() listing each of your
// javascript files that are in your html as <script src="..."></script>
.pipe(uglify())
.pipe(gulp.dest('./build/'));
});
The text was updated successfully, but these errors were encountered: