Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/retyui/postcss-mimic.css-data

PostCSS plugin that adds `@keyframes` from mimic.css
https://github.com/retyui/postcss-mimic.css-data

Last synced: 16 days ago
JSON representation

PostCSS plugin that adds `@keyframes` from mimic.css

Awesome Lists containing this project

README

        

# postcss-mimic.css-data

Autogenerated data for [postcss-animations](https://github.com/retyui/postcss-animations) plugin.

Parsed all `@keyframes` from [magic.css](https://minimamente.com/example/magic_animations/).

## Install

```bash
yarn add -D postcss-mimic.css-data postcss-animations
# or npm i -D postcss-mimic.css-data postcss-animations
```

## Use

```js
const postcss = require("postcss");
const postcssAnimations = require("postcss-animations");

(async () => {
const CSS = `.my-tearDrop { animation-name: tearDrop; }`;
const PLUGINS = [
postcssAnimations({
data: [require("postcss-mimic.css-data")],
checkDuplications: true,
disableCheckCssVariables: true
})
];

try {
const { css, messages } = await postcss(PLUGINS).process(
CSS /*, {from,to}*/
);
messages.map(msg => console.log(msg.toString()));

console.log(css);
/*
.my-tearDrop { animation-name: tearDrop; }
@keyframes tearDrop { }
*/
} catch (e) {
console.error(e);
}
})();
```

## Other animation data:

* [![npm postcss-animation.css-data](https://img.shields.io/npm/dm/postcss-animation.css-data.svg)](https://www.npmjs.com/package/postcss-animation.css-data) [postcss-animation.css-data](https://github.com/retyui/postcss-animation.css-data)
* [![npm postcss-magic.css-data](https://img.shields.io/npm/dm/postcss-magic.css-data.svg)](https://www.npmjs.com/package/postcss-magic.css-data) [postcss-magic.css-data](https://github.com/retyui/postcss-magic.css-data)
* [![npm postcss-tuesday.css-data](https://img.shields.io/npm/dm/postcss-tuesday.css-data.svg)](https://www.npmjs.com/package/postcss-tuesday.css-data) [postcss-tuesday.css-data](https://github.com/retyui/postcss-tuesday.css-data)

## Update data:

```bash
git clone https://github.com/retyui/postcss-mimic.css-data
cd postcss-mimic.css-data
yarn
yarn build
```