A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://npmjs.org/package/insert-css below:

insert-css - npm

insert-css

insert a string of css into the <head>

example

    var insertCss = require('insert-css');

    var styleElement = insertCss('body { background:blue; }');

api

    var insertCss = require('insert-css');

var styleElement = insertCss(css, opts);

Insert some CSS into the page.

This is particullary useful for library creators where you may want your default CSS to be prepended so it can be easily overriden by user styles.

development example

npm run example

test

npm test


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4