0.1.1 • Published 7 years ago

jstransformer-posthtml v0.1.1

Weekly downloads
1
License
MIT
Repository
github
Last release
7 years ago

jstransformer-posthtml

PostHTML support for JSTransformers.

Build Status Coverage Status Dependency Status NPM version

Installation

npm install jstransformer-posthtml

API

var posthtml = require('jstransformer')(require('jstransformer-posthtml'))
var html = '<myComponent><myTitle>Super Title</myTitle><myText>Awesome Text</myText></myComponent>'
var options = {
  plugins: [
    'posthtml-custom-elements'
  ]
}

posthtml.render(html, options).body
//=> <div class="myComponent"><div class="myTitle">Super Title</div><div class="myText">Awesome Text</div></div>

License

MIT