# lightningcss-loader

[Lightning CSS](https://lightningcss.dev) loader for [Webpack](https://webpack.js.org)

## Usage

```js
import { transform } from 'lightningcss';

return {
    ...,
    rules: [
        {
            test: /\.css$/,
            use: [
                {
                    loader: '@advdominion/lightningcss-loader',
                    options: {
                        implementation: transform,
                    },
                },
            ],
        },
    ],
};
```

### Passing options to Lightning CSS

```js
import { transform } from 'lightningcss';

return {
    ...,
    rules: [
        {
            test: /\.css$/,
            use: [
                {
                    loader: '@advdominion/lightningcss-loader',
                    options: {
                        implementation: transform,
                        drafts: {
                            customMedia: true,
                        },
                        minify: false,
                    },
                },
            ],
        },
    ],
};
```
