postcss-merge-idents
Merge keyframe and counter style identifiers.
Last updated 4 years ago by ludovicofischer .
MIT · Repository · Bugs · Original npm
$ cnpm install postcss-merge-idents 
SYNC missed versions from official npm registry.

postcss-merge-idents

Merge keyframe and counter style identifiers.

Install

With npm do:

npm install postcss-merge-idents --save

Example

This module will merge identifiers such as @keyframes and @counter-style, if their properties are identical. Then, it will update those declarations that depend on the duplicated property.

Input

@keyframes rotate {
    from { transform: rotate(0) }
    to { transform: rotate(360deg) }
}

@keyframes flip {
    from { transform: rotate(0) }
    to { transform: rotate(360deg) }
}

.rotate {
    animation-name: rotate
}

.flip {
    animation-name: flip
}

Output

@keyframes flip {
    from { transform: rotate(0) }
    to { transform: rotate(360deg) }
}

.rotate {
    animation-name: flip
}

.flip {
    animation-name: flip
}

Usage

See the PostCSS documentation for examples for your environment.

Contributors

See CONTRIBUTORS.md.

License

MIT © Ben Briggs

Current Tags

  • 6.0.0                                ...           latest (2 years ago)

6 Versions

  • 6.0.0                                ...           2 years ago
  • 4.0.0-nightly.2020.2.6                                ...           5 years ago
  • 5.0.0-rc.2                                ...           4 years ago
  • 5.1.1                                ...           3 years ago
  • 1.0.2                                ...           10 years ago
  • 2.1.7                                ...           9 years ago
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (2)
Dev Dependencies (1)
Dependents (0)
None

Copyright 2013 - present © cnpmjs.org