Open subinvarghesein opened 9 years ago
Following is my relevant code:
gulp.task('scripts', ['clean'], function() { return gulp. src('src/**/*.js'). pipe(sourcemaps.init()). pipe(uglify()). pipe(concat('script.js')). pipe(sourcemaps.write('.')). pipe(cachebust.resources()). pipe(gulp.dest("/dist")); });
Now, the files generated are: script.12345678.js and script.js.87654321.map
script.12345678.js
script.js.87654321.map
In short, cachebust token is getting added to the sourcemap file but inside script.js, sourcemap url is script.js.map.
script.js
script.js.map
So how should this be handled?
Please try to put pipe(cachebust.resources()). before pipe(sourcemaps.write('.')).
pipe(cachebust.resources()).
pipe(sourcemaps.write('.')).
Following is my relevant code:
Now, the files generated are:
script.12345678.js
andscript.js.87654321.map
In short, cachebust token is getting added to the sourcemap file but inside
script.js
, sourcemap url isscript.js.map
.So how should this be handled?