# light-tpl [![NPM version](https://img.shields.io/npm/v/light-tpl)](https://www.npmjs.com/package/light-tpl) [![License MIT](https://img.shields.io/npm/l/light-tpl)](https://github.com/fh332393900/light-tpl/blob/master/LICENSE) [![NPM size](https://img.shields.io/bundlephobia/min/light-tpl?color=orange)](https://www.npmjs.com/package/light-tpl) [![NPM downloads](https://img.shields.io/npm/dw/light-tpl)](https://www.npmjs.com/package/light-tpl) :lemon: :tangerine: :cherries: :cake: :grapes: :watermelon: :strawberry: :corn: :peach: :melon: ## How to use You can install using npm ```bash npm i light-tpl ``` Output the template as a function return value ```javascript let tpl = require('light-tpl') export default function myTest() { let data = [ {name:"fenghang",phone:"15900001111",age:21}, {name:"222",phone:"110",age:50}] let template = ` ` return tpl(template,data) } ``` result: ```html ``` Rendered HTML: * 我的名字是fenghang,我的年龄是21,我的手机号:15900001111 * my name is 222,my age is a sercet.