inlineresources

WebJar for inlineresources

License

License

MIT
GroupId

GroupId

org.webjars.npm
ArtifactId

ArtifactId

inlineresources
Last Version

Last Version

0.4.0
Release Date

Release Date

Type

Type

jar
Description

Description

inlineresources
WebJar for inlineresources
Project URL

Project URL

http://webjars.org
Source Code Management

Source Code Management

https://github.com/cburgmer/inlineresources

Download inlineresources

How to add to project

<!-- https://jarcasting.com/artifacts/org.webjars.npm/inlineresources/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>inlineresources</artifactId>
    <version>0.4.0</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/inlineresources/
implementation 'org.webjars.npm:inlineresources:0.4.0'
// https://jarcasting.com/artifacts/org.webjars.npm/inlineresources/
implementation ("org.webjars.npm:inlineresources:0.4.0")
'org.webjars.npm:inlineresources:jar:0.4.0'
<dependency org="org.webjars.npm" name="inlineresources" rev="0.4.0">
  <artifact name="inlineresources" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='inlineresources', version='0.4.0')
)
libraryDependencies += "org.webjars.npm" % "inlineresources" % "0.4.0"
[org.webjars.npm/inlineresources "0.4.0"]

Dependencies

compile (3)

Group / Artifact Type Version
org.webjars.npm : url jar [0.11.0,0.12)
org.webjars.npm : css-font-face-src jar [1.0.0,2)
org.webjars.npm : cssom Optional jar [0.3.0,0.4)

Project Modules

There are no modules declared in this project.

inlineresources

NPM version

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 (<div style="...">)
  • Media queries defined on link elements (<link rel="stylesheet" media="..." />)
  • Media queries defined on import rules (@import url("...") screen and (orientation:landscape);)
  • Future responsive img solution (<img srcset="...">)

Similar projects for Node.js

Development

For linting, tests and a browser build install Node.js and run

$ npm install && npm test

Check ./dist/ for the browserified builds.

To test against several browsers while editing, run grunt testWatch and point those browsers to http://localhost:9989/.

Build Status

Where is it used?

Author

Christoph Burgmer. Licensed under MIT. Reach out on Twitter.

Versions

Version
0.4.0
0.3.2