gulp-community / gulp-concat

Streaming concat middleware for gulp
MIT License
792 stars 127 forks source link

when used with gulp-sourcemaps source file names in source map are the name of the concat'ed file. #134

Closed twiggy closed 7 years ago

twiggy commented 7 years ago

Having an issue when used with concat where the sources [] array is all the name of concated file for all sources. So if you where concating 100 *.js files you will get a source map array like [ 'concated.js', 'concated.js'.... ] for all 100 files.

Rolling back to 2.6.0 fixed our issues. this is with all source map versions we tested, but specifically with 2.3.0 which is the latest.

This is the basic flow.

.pipe(sourcemaps.init()) .pipe(concat('bundle.js')) .pipe(sourcemaps.write())

We do set a a write path inside of write().

twiggy commented 7 years ago

Second guessing myself with npm dependencies here. Might be in sourcemaps court. Closing out.