【发布时间】:2016-07-15 12:23:08
【问题描述】:
我正在尝试构建我的第一个 Angular 应用程序。我正在使用 yeoman 和 angular-generator。该应用程序使用“grunt serve”运行良好,但是当我运行“grunt build”时,该过程因错误而停止 -
Running "cssmin:generated" (cssmin) task
Warning: Broken @import declaration of "" Use --force to continue.
Aborted due to warnings.
我不确定这个错误的原因是什么。我到处寻找,但找不到解决方案。 这是css链接-
<!-- build:css(.) styles/vendor.css -->
<!-- bower:css -->
<link rel="stylesheet" href="bower_components/bootstrap/dist/css/bootstrap.css" />
<link rel="stylesheet" href="bower_components/animate.css/animate.css" />
<!-- endbower -->
<!-- endbuild -->
<!-- build:css(.tmp) styles/main.css -->
<link rel="stylesheet" href="styles/main.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css">
<link href="https://fonts.googleapis.com/css?family=Bungee|Carrois+Gothic+SC|Oswald" rel="stylesheet">
<base href="/">
<!-- endbuild -->
【问题讨论】:
-
您在导致问题的文件中有
@import句子。但由于您不与我们分享,我们无法帮助您。我投票将此作为offtopic关闭>为什么这段代码不起作用。 -
我很确定我没有在我的代码中的任何地方写过@import。而且我共享代码没有问题,但是有很多,所以我不确定在这里展示哪个部分会有用。
标签: javascript css angularjs gruntjs yeoman