Skip to content

PostHTML plugin to insert content after HTML tag.

Notifications You must be signed in to change notification settings

ratson/posthtml-insert

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

posthtml-insert

PostHTML plugin to insert content after HTML tag.

Installation

npm install posthtml-insert --save

Usage

const posthtml = require('posthtml')
const insert = require('posthtml-insert')

posthtml([insert({ selector: 'body', content: '<div>test</div>' })])
  .process('<body></body>')
  .then(({ html }) => {
    console.log(html)
    // => '<body><div>test</div></body>'
  })

About

PostHTML plugin to insert content after HTML tag.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published