---
title: "更改ejs模板后缀.ejs为.html "
author: "mofeichen"
date: "2015-03-25T16:12:17Z"
tags: []
categories: ["Web前端"]
slug: "ejs-ejs-html"
draft: false
lastmod: "2015-03-25T16:12:17Z"
id: 2195511
url: "https://mofeichen.iteye.com/blog/2195511"
---

1. app.engine('.html', require('ejs').\_\_express);
2. app.set('view engine', 'html');