Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/laravel/10.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Twitter bootstrap Laravel Elixir sass依赖路径_Twitter Bootstrap_Laravel_Npm_Sass - Fatal编程技术网

Twitter bootstrap Laravel Elixir sass依赖路径

Twitter bootstrap Laravel Elixir sass依赖路径,twitter-bootstrap,laravel,npm,sass,Twitter Bootstrap,Laravel,Npm,Sass,我在用拉维5.2和长生不老药。 我将引导材质设计与引导sass一起使用时出错,gulp任务返回以下内容: gulp-notify: [Laravel Elixir] Sass Compilation Failed: node_modules/bootstrap-material-design/sass/_import-bs-sass.scss Error: File to import not found or unreadable: bootstrap/variables Par

我在用拉维5.2和长生不老药。 我将引导材质设计与引导sass一起使用时出错,gulp任务返回以下内容:

gulp-notify: [Laravel Elixir] Sass Compilation Failed: node_modules/bootstrap-material-design/sass/_import-bs-sass.scss
Error: File to import not found or unreadable: bootstrap/variables
       Parent style sheet: /workspace/node_modules/bootstrap-material-design/sass/_import-bs-sass.scss
       on line 1 of node_modules/bootstrap-material-design/sass/_import-bs-sass.scss
>> @import "bootstrap/variables";
当我用这个替换线路时,它可以工作

@import "../../bootstrap-material-design/sass/variables";
在我的大口文件中,我有:

elixir(function(mix) {
mix
    .browserSync({
        proxy : 'http'
    })
    .sass('app.scss')
    .browserify('app.js')
    .version(["public/css/app.css","public/js/app.js"]);
});
@import "node_modules/bootstrap-sass/assets/stylesheets/bootstrap";
@import "node_modules/bootstrap-material-design/sass/bootstrap-material-design";
在我的app.scss中,我有:

elixir(function(mix) {
mix
    .browserSync({
        proxy : 'http'
    })
    .sass('app.scss')
    .browserify('app.js')
    .version(["public/css/app.css","public/js/app.js"]);
});
@import "node_modules/bootstrap-sass/assets/stylesheets/bootstrap";
@import "node_modules/bootstrap-material-design/sass/bootstrap-material-design";

我做错了什么?

我找到了解决方案,这是我的
gulpfile.js

elixir(function(mix) {
    mix
        .browserSync({
            proxy : 'http'
        })
        .sass('app.scss', "public/css/app.css", {
            includePaths: ['node_modules/bootstrap-sass/assets/stylesheets/']
        })
        .browserify('app.js')
        .version(["public/css/app.css","public/js/app.js"]);
});