diff --git a/README.md b/README.md index f72f8b3..631cbad 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,9 @@ # ejs-mate ## Status -- [![NPM version](https://badge.fury.io/js/ejs-mate.png)](http://badge.fury.io/js/ejs-mate) -- [![Build Status](https://travis-ci.org/JacksonTian/ejs-mate.png?branch=master)](https://travis-ci.org/JacksonTian/ejs-mate) -- [![Dependencies Status](https://david-dm.org/JacksonTian/ejs-mate.png)](https://david-dm.org/JacksonTian/ejs-mate) -- [![Coverage Status](https://coveralls.io/repos/JacksonTian/ejs-mate/badge.png)](https://coveralls.io/r/JacksonTian/ejs-mate) +[![NPM version](https://badge.fury.io/js/ejs-mate.png)](http://badge.fury.io/js/ejs-mate) +[![Node.js CI](https://github.com/JacksonTian/ejs-mate/actions/workflows/node.js.yml/badge.svg)](https://github.com/JacksonTian/ejs-mate/actions/workflows/node.js.yml) +[![codecov](https://codecov.io/gh/JacksonTian/ejs-mate/branch/master/graph/badge.svg?token=xQKwDgJpbe)](https://codecov.io/gh/JacksonTian/ejs-mate) ## About @@ -146,14 +145,12 @@ $ npm test ## Whither Include? -Previous versions of this library had an `include` function. This is now supported directly by EJS, albeit with a different syntax. For `ejs-locals` 1.0+ simply do: +We upgrade EJS to v3.x, it used as a method now: ```html -<% include path/view %> +<%- include('path/view') %> ``` -When called anywhere inside a template, this adds the given view to that template using the current options and locals. This is built-in to [EJS](https://github.com/visionmedia/ejs) 1.0+. - ## Credits This library is a fork from Robert Tom Carden's [ejs-locals](https://github.com/RandomEtc/ejs-locals), and the partial function remains relatively untouched from there (aside from cache support). Robert is still updating his library and it now supports other template engines - check it out!