Yeoman/Grunt:向项目添加子目录

Yeoman / Grunt: adding subdirectories to project

本文关键字:项目 添加 子目录 Grunt Yeoman      更新时间:2023-09-26

我正在用Yeoman构建一个web,并试图创建以下结构:

app/index.html -> /
app/support/index.html -> /support
...etc

当我运行grunt来构建dist目录时,问题就出现了。support子目录中的文件不会得到处理。

如何实现这一点

这取决于您使用的生成器,但大多数情况下,您需要将Gruntfile.js中的*.html{,*/}*.html行更改为**/*.html,以便它也可以在子目录中查找。