Parse HTML script tags into JSON.
npm install script-tags> Parse HTML script tags into JSON.
- Install
- scripts(html)
- Related projects
- Running tests
- Contributing
- Author
- License
_(TOC generated by verb using markdown-toc)_
Install with npm:
``sh`
$ npm install script-tags --save
Install with bower:
`bash`
bower install script-tags
* html: pass a string of HTML with the script tags to be parsedattrs
* returns an array, an object for each script tag, each with a property and a html property.
Example:
`js`
var scripts = require('script-tags');
console.log(scripts(''));
//=> [{ "attrs": { "src": "bootstrap.js" }, "html": ""}]
See example.
* strip-attributes: Strip attributes from HTML tags. | homepage
* strip-tags: Strip specific tags from a string of HTML | homepage
Install dev dependencies:
`sh``
$ npm i -d && npm test
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
Jon Schlinkert
* github/jonschlinkert
* twitter/jonschlinkert
Copyright © 2016 Jon Schlinkert
Released under the MIT license.
*
_This file was generated by verb on January 05, 2016._