postcss-ie8

Strips properties and selectors that are unsupported by IE8

Usage no npm install needed!

<script type="module">
  import postcssIe8 from 'https://cdn.skypack.dev/postcss-ie8';
</script>

README

postcss-ie8

postcss plugin for transforming a stylesheet to an IE8-compatible stylesheet.

Installation

npm install postcss-ie8

Options

selectors

Type: Array

Array with regular expressions of selectors which should be removed.

Example

{
    selectors: [
        /:last-child/,
        /:nth-child/,
        /:nth-last-child/,
    ]
}

atRules

Type: Array

Array of atRules to remove.

Default

{
    atRules: [
        'keyframes',
        'supports',
        'document',
    ]
}

removePrefixes

Type: Boolean Default: false

Remove all prefixes in declarations.

properties

Type: Array

Array with regular expressions of properties which should be removed.

values

Type: Array

Array with regular expressions of values which should be removed.

mqOptions

Type: Object

Options for css-mediaquery.

Default

{
    type: 'screen',
    width: '1024px'
}