koistya / gulp-csscomb

CSScomb plugin for Gulp.js. Formats CSS according to a pre-defined coding style.
http://csscomb.com
MIT License
122 stars 23 forks source link

sourcemap ломается( #21

Open romanlex opened 8 years ago

romanlex commented 8 years ago

Почему то при использовании csscomb ломается sourcemap и в dev tool браузера ссылки на файлы меняются

gulp.task('style_stylus:build', function() {
    return gulp.src(path.src.style.stylus)
        .pipe(plumber())
        .pipe(sourcemaps.init())
        .pipe(stylus({
            use: [ autoprefixer_stylus({ browsers : ["last 4 version", 'ie 8', 'ie 9', '> 5%'] })],
        }))
        //.pipe(csscomb())
        .pipe(gulp.dest(path.build.css))
        .pipe(nano({zindex: false, mergeRules: false, discardComments: {removeAll: true}}))
        .pipe(rename({suffix: '.min'}))
        .pipe(sourcemaps.write('./', {
            includeContent: false,
            relativeToSourcePath: '/build',
            sourceRoot: '/src/style/stylus'
        }))
        .pipe(gulp.dest(path.build.css))
        .pipe(plumber.stop())
        .pipe(reload({stream: true, match: '**/*.css'}))
        .pipe(notify({ title: '[Gulp] CSS Build', message: 'Stylus task complete', onLast: true, wait: false }));
});
ghost commented 8 years ago

Please, add sourcemap support. E.g.

wolfy1339 commented 8 years ago

Very appreciate if this was to get added in a future release

terryupton commented 7 years ago

+1 for sourcemap

fedorovsky commented 7 years ago

+1 for sourcemap

Hrommi commented 6 years ago

Можно использовать gulp-if и применять csscomb только при финальной сборке проекта.

Alecto commented 5 years ago

the same problem