如何将 pug 添加到 angular-cli? [英] How to add pug to angular-cli?
本文介绍了如何将 pug 添加到 angular-cli?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
有人有幸将 .pug 添加到 angular-cli 吗?
Anyone having luck adding .pug to angular-cli?
我尝试执行 npm install pug --save,但我不知道在哪里更改 .pug 渲染而不是 .html.
I tried to do npm install pug --save, but I don't know where to change the .pug rendering instead of .html.
angular-cli 的链接在这里
Link for the angular-cli is here
请分享一个简短的教程,这将有助于很多人:)
Please share a short tutorial, that would help a lof of people :)
推荐答案
对于 Angular 6+,您只需在根文件夹中运行 ng add ng-cli-pug-loader 命令即可打开 pug支持您的 anglar-cli 项目.
For Angular 6+ you can simply run ng add ng-cli-pug-loader command in the root folder to turn on pug support in your angilar-cli project.
这篇关于如何将 pug 添加到 angular-cli?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文