postcss-merge-idents
    TypeScript icon, indicating that this package has built-in type declarations

    5.1.1 • Public • Published

    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

    Install

    npm i postcss-merge-idents

    DownloadsWeekly Downloads

    788,474

    Version

    5.1.1

    License

    MIT

    Unpacked Size

    7.89 kB

    Total Files

    5

    Last publish

    Collaborators

    • beneb
    • trysound
    • ludovicofischer
    • ai
    • chriseppstein
    • andyjansson
    • evilebottnawi
    • cssnano-bot