Skip to content

Latest commit

 

History

History
39 lines (28 loc) · 870 Bytes

File metadata and controls

39 lines (28 loc) · 870 Bytes

PostCSS Remove Double Parentheses

This PostCSS plugin removes double parentheses around media queries, for example, @media ((min-width: 700px)) {}. Without this, older Safari browsers (before version 16.5) may not interpret the media queries at all.

Installation

npm install @locomotivemtl/postcss-remove-double-parentheses --save-dev

Usage

Basic Example

Import the plugin in your PostCSS configuration

const removeDoubleParentheses = require('@locomotivemtl/postcss-remove-double-parentheses');

module.exports = {
    plugins: [
        removeDoubleParentheses(),
        // other plugins
    ]
};

Basic Example (ESM)

import removeDoubleParentheses from '@locomotivemtl/postcss-remove-double-parentheses';

export default {
    plugins: [
        removeDoubleParentheses(),
        // other plugins
    ]
};