Socket
Socket
Sign inDemoInstall

postcss-merge-idents

Package Overview
Dependencies
6
Maintainers
8
Versions
47
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    postcss-merge-idents

Merge keyframe and counter style identifiers.


Version published
Weekly downloads
592K
decreased by-16.47%
Maintainers
8
Created
Weekly downloads
 

Readme

Source

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

Keywords

FAQs

Last updated on 24 Apr 2024

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc