【发布时间】:2019-10-08 06:21:53
【问题描述】:
假设我有下面的 HTML 模板,将它分配给 Angular 项目中的变量的最佳方法是什么
public template = '<html><body> <p>This is a p tag</p>
</body></html>'
我如何在打字稿中进行这样的分配?
【问题讨论】:
-
问题中的代码不起作用?
-
只是一个html标签
-
我的意思是如果它是一个大模板,那么将它分配给变量的最佳方法是什么。
标签: angular typescript email let