Inlines style sheets, images, fonts and scripts in HTML documents. Works in the browser.
npm install inlineresourcesinlineresources
===============
align="right" alt="NPM version" height="18">
Inlines style sheets, images, fonts and scripts in HTML documents. Works in the browser.
See the API.
Install
-------
$ npm install inlineresources
and require through browserify or webpack.
Alternatively use a standalone bundle via e.g. https://wzrd.in/standalone/inlineresources@latest.
Limitations
-----------
Resources referenced in the document (CSS, images, fonts and JS) can only be loaded if from the same origin, unless techniques like CORS are used.
Yet to be supported:
* Background images in inline style declarations ( Similar projects for Node.js * jasonbellamy/asset-inliner Development For linting, tests and a browser build install Node.js and run $ npm install && npm test Check To test against several browsers while editing, run  Where is it used? * rasterizeHTML.js, Renders HTML into the browser's canvas Author)
* Media queries defined on link elements ()
* Media queries defined on import rules (@import url("...") screen and (orientation:landscape);)
* Future responsive img solution ()
----------------------------
* cdata/collapsify
* EE/grunt-inline-images
* popeindustries/inline-source
* LearnBoost/juice
* fb55/node-inline
* callumlocke/resource-embedder
* kevva/rework-inline
* andreypopp/xcss-inline-woff
* ... and many more
-----------./dist/ for the browserified builds.grunt testWatch and point those browsers to http://localhost:9989/.
-----------------
* ...
------
Christoph Burgmer. Licensed under MIT. Reach out on Twitter.