报错:A valid Gruntfile could not be found. Please see the getting started guide for
more information on how to configure grunt: http://gruntjs.com/getting-started
Fatal error: Unable to find Gruntfile.
解决办法:在当前目录下添加一个Gruntfile.js文件
// 包装函数
module.exports = function(grunt) {
// 任务配置
grunt.initConfig({
'hello-world':{}
});
// 自定义任务
grunt.registerTask('hello-world', 'My "asyncfoo" task.', function() {
grunt.log.writeln('hello world');
});
grunt.registerTask('default', ['hello-world']);
};
就可以了。
欢迎加入 优快云技术交流群:(点击即可加群)QQ群:681223095,方便问题讨论。本博主不一定长期在线,但是qq群里会有很多热心的小伙伴,大家一起讨论解决问题。
关注公众号,更多学习内容给予推送,争取每日更新