我目前正在尝试更新我们的 Web 应用程序及其构建工具的样板。
我目前收到此错误:
events.js:85
throw er; // Unhandled 'error' event
^
Error: Broken @import declaration of "branding", Broken @import declaration of "helper", Broken @import declaration of "routing"
我假设这是某种缓存问题,因为它应该解析的 .scss 文件是空的。具有类似branding
和文件的项目routing
是另一个项目,我绝对没有在终端的错误文件夹中。
我该如何解决这个问题?我可以/我应该清除缓存吗?如何?
为了完成: Gulpfile 样式任务:
// Styles
gulp.task('styles', function() {
return sass('src/css/app.scss', {
sourcemap: true,
noCache: true
})
.on('error', function (err) {
console.error('Error', err.message);
})
.pipe(autoprefixer('last 2 version', 'safari 5', 'ie 8', 'ie 9', 'opera 12.1', 'ios 6', 'android 4'))
.pipe(rename({ suffix: '.min' }))
.pipe(minifycss())
.pipe(gulp.dest('dist/css'))
.pipe(notify({ message: 'Styles task complete' }));
});
包.json
{
"name": "boilerplate",
"version": "1.0.0",
"description": "Download as ZIP, **don't clone this repo** if you want to create a new project. Only clone if you want to update/change the boilerplate.",
"main": "gulpfile.js",
"dependencies": {
"bower": "^1.3.12",
"del": "^1.1.1",
"gulp-autoprefixer": "^2.1.0",
"gulp": "^3.8.11",
"gulp-concat": "^2.5.1",
"gulp-minify-css": "^0.4.6",
"gulp-notify": "^2.2.0",
"gulp-rename": "^1.2.0",
"gulp-jshint": "^1.9.2",
"gulp-ruby-sass": "^1.0.0",
"gulp-uglify": "^1.1.0",
"main-bower-files": "git://github.com/ck86/main-bower-files"
},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "https://codeofsumit:091210sk@github.com/codeofsumit/boilerplate.git"
},
"author": "",
"license": "ISC",
"bugs": {
"url": "https://github.com/codeofsumit/boilerplate/issues"
},
"homepage": "https://github.com/codeofsumit/boilerplate"
}