首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >将静态html页面与角6+混合

将静态html页面与角6+混合
EN

Stack Overflow用户
提问于 2019-12-17 13:39:43
回答 1查看 197关注 0票数 0

在不为每个页面编写空组件的情况下,将静态html页面与角6+应用程序混合时,最佳做法是什么?

静态页面比如..。

EN

回答 1

Stack Overflow用户

发布于 2019-12-17 14:00:08

代码语言:javascript
复制
ng-build with your index.html set properly with its components. (or conditional app-components)
rename and copy the rendered to (for example) /src/assests/aboutus.html
in angular.json find "assets":

 "assets": [
      "src/favicon.ico",
      "src/assets",
      "src"
    ],
browse localhost:4200/aboutus.html directly.
Always place the static contents in assets folder, thats a good practice.
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/59375508

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档