preact-glam
Version:
A tiny glamorous implementation for preact
56 lines (37 loc) • 2.16 kB
Markdown
# preact-glam
> A tiny glamorous implementation for preact
[](https://travis-ci.org/vesparny/preact-glam)
[](https://david-dm.org/vesparny/preact-glam)
[](https://www.npmjs.com/package/preact-glam)
[](https://npm-stat.com/charts.html?package=preact-glam&from=2017-04-01)
[](http://standardjs.com/)
[](https://github.com/vesparny/preact-glam/blob/master/LICENSE)
The current size of `preact-glam/dist/preact-glam.umd.min.js` is:
[](https://unpkg.com/preact-glam/dist/)
> IMPORTANT NOTE ABOUT SIZE: Because `preact-glam` depends on `glamor`, you should consider the full size you'll be adding
> to your application if you don't already have `glamor`.
## Install
This project uses [node](http://nodejs.org) and [npm](https://npmjs.com). Go check them out if you don't have them locally installed.
```sh
$ yarn add preact-glam
```
Then with a module bundler like [rollup](http://rollupjs.org/) or [webpack](https://webpack.js.org/), use as you would anything else:
```javascript
// using ES6 modules
import glam from 'preact-glam'
// using CommonJS modules
var glam = require('preact-glam')
```
The [UMD](https://github.com/umdjs/umd) build is also available on [unpkg](https://unpkg.com):
```html
<script src="https://unpkg.com/preact-glam/dist/preact-glam.umd.js"></script>
```
You can find the library on `window.preactGlam`.
## Usage
Please refer to [glamorous-tiny](https://github.com/paypal/glamorous#size).
It should support all the features supported by `glamorous-tiny`.
## Tests
```sh
$ yarn run test
```
[MIT License](LICENSE.md) © [Alessandro Arnodo](https://alessandro.arnodo.net/)