Gulp-sass fails to compile scss file

前端 未结 3 852
佛祖请我去吃肉
佛祖请我去吃肉 2021-02-05 17:57

I\'m using Gulp to compile my sass into css. A simple task compiles the style.scss file in the _/sass directory and saves the output into the root of t

3条回答
  •  灰色年华
    2021-02-05 18:13

    Keep your imports as is, just pass the includePaths option in your gulp sass module as an argument:

    gulp.src('./_/sass/style.scss')
            .pipe(sass({ includePaths : ['_/sass/'] }))
            .pipe(gulp.dest('./'));
    

    ...should do it for you.

    As per https://github.com/dlmanning/gulp-sass/issues/1

提交回复
热议问题