摘要: express默认使用jade模板,可以配置让其支持使用ejs或html模板。 1. 安装ejs 在项目根目录安装ejs. 2、引入ejs 3、设置html引擎 设置视图引擎 保存后重启服务,即可访问html文件。 注:在express搭建的服务器中,html引擎没有被配置,直接添加即可;视图引擎已 阅读全文
posted @ 2015-11-06 18:26 -nothing- 阅读(33075) 评论(0) 推荐(1) 编辑