Express 在PUG中实现类似HTML的模板
我正试图实现类似html的模板在帕格与Express 在PUG中实现类似HTML的模板,express,pug,ejs,Express,Pug,Ejs,我正试图实现类似html的模板在帕格与 #{name} 但这不起作用,它双重打印,然后我使用管道字符 |#{name} 但是它的输出是h1这是Contenth1> 我的完整模板是 <html lang="en"> <head> SomeRandomStuff </head> <body> |#{Content} </body> Scripts </html> 一些随机的东西 |#{Co
#{name}
但这不起作用,它双重打印,然后我使用管道字符
|#{name}
但是它的输出是h1这是Contenth1>
我的完整模板是
<html lang="en">
<head>
SomeRandomStuff
</head>
<body>
|#{Content}
</body>
Scripts
</html>
一些随机的东西
|#{Content}
剧本
使用!{name}
一些随机的东西
!{Content}
剧本
似乎是文本编码问题,您可以分享文本应该是什么的图片吗?尝试将此html头元(charset=“utf-8”)
添加到文件顶部