1.0.3 • Published 4 months ago

style2js v1.0.3

Weekly downloads
5
License
MIT
Repository
github
Last release
4 months ago

Style2js

Generate helpers to inject your css into the dom when no css loader is available.

For example the command below will output 3 files into your dist folder

style2js style.min.css --out-dir ./dist
|_ inject-style.js
|_ inject-style.esm.js
|_ inject-style.d.ts

When someone use your library, he can do the following to load the css

import { injectStyle } from "your-library/inject-style";
// inject the stylesheet into the dom
injectStyle();

Installation

You can install the package with npm or yarn

npm i style2js
// with yarn
yarn add style2js

Or use it directly via npx

npx style2js
1.0.2

4 months ago

1.0.3

4 months ago

1.0.1

2 years ago

1.0.0

3 years ago

0.0.1

3 years ago