Template engines模板引擎
Warning:
The packages listed below may be outdated, no longer maintained or even broken. 下面列出的包装可能已经过时,不再维护,甚至损坏。Listing here does not constitute an endorsement or recommendation from the Expressjs project team. Use at your own risk.此处列出的内容并不构成Expressjs项目团队的认可或建议。使用风险自负。
These template engines work “out-of-the-box” with Express:这些模板引擎使用Express“开箱即用”:
- Pug:
Haml-inspired template engine (formerly Jade).受Haml启发的模板引擎(前身为Jade)。
- Haml.js:
Haml implementation.Haml实现。
- EJS:
Embedded JavaScript template engine.嵌入式JavaScript模板引擎
- hbs:
Adapter for Handlebars.js, an extension of Mustache.js template engine.Handlebar.js适配器,Mustache.js模板引擎的扩展。
- Squirrelly:
Blazing-fast template engine that supports partials, helpers, custom tags, filters, and caching. Blazing fast模板引擎,支持部分、帮助程序、自定义标记、过滤器和缓存。Not white-space sensitive, works with any language.不区分空格,适用于任何语言。
- Eta:
Super-fast lightweight embedded JS template engine. Supports custom delimiters, async, whitespace control, partials, caching, plugins.超快速轻量级嵌入式JS模板引擎。支持自定义分隔符、异步、空白控制、分区、缓存和插件。
- React:
Renders React components on the server. 在服务器上呈现React组件。It renders static markup and does not support mounting those views on the client.它呈现静态标记,不支持在客户机上装载这些视图。
- combyne.js:
A template engine that hopefully works the way you’d expect.一个模板引擎,希望能以您期望的方式工作。
- Nunjucks:
Inspired by jinja/twig.灵感来源于jinja/twig。
- marko:
A fast and lightweight HTML-based templating engine that compiles templates to CommonJS modules and supports streaming, async rendering and custom tags. (Renders directly to the HTTP response stream).一个快速轻量级的基于HTML的模板引擎,可将模板编译为CommonJS模块,并支持流式、异步呈现和自定义标记。(直接呈现到HTTP响应流)。
- whiskers:
Small, fast, mustachioed.又小又快的胡子。
- Blade:
HTML Template Compiler, inspired by Jade & Haml.HTML模板编译器,灵感来自Jade和Haml。
- Haml-Coffee:
Haml templates where you can write inline CoffeeScript.Haml模板,您可以在其中编写内联咖啡脚本。
- express-hbs:
Handlebars with layouts, partials and blocks for express 3 from Barc.Barc express 3带布局、部件和挡块的把手。
- express-handlebars:
A Handlebars view engine for Express which doesn’t suck.一个车把视图引擎的快车不吸。
- express-views-dom:
A DOM view engine for Express.Express的DOM视图引擎。
- rivets-server:
Render Rivets.js templates on the server.在服务器上呈现铆钉.js模板。
- LiquidJS:
A simple, expressive and safe template engine.一个简单,表达和安全的模板引擎。
- express-tl:
A template-literal engine implementation for Express.Express的模板文本引擎实现。
- Twing:
First-class Twig engine for Node.js.Node.js的一流细枝引擎。
- Sprightly:
A very light-weight JS template engine (45 lines of code), that consists of all the bare-bones features that you want to see in a template engine.一个非常轻量级的JS模板引擎(45行代码),它包含您希望在模板引擎中看到的所有基本功能。
The Consolidate.js library unifies the APIs of these template engines to a single Express-compatible API.Consolidate.js库将这些模板引擎的API一致性为一个与Express兼容的API。
Add your template engine here!在这里添加你的模板引擎!
Edit the Markdown file and add a link to your project, then submit a pull request (GitHub login required). Follow the format of the above listings.