Purgecss: type definition of `css` `raw` option

Created on 14 Jul 2018  路  1Comment  路  Source: FullHuman/purgecss

Correct me if I'm wrong
According to the doc example for using css with raw content, the extension property is not required correct?

new Purgecss({
    content: [
        {
            raw: '<html><body><div class="app"></div></body></html>',
            extension: 'html'
        },
        '**/*.js', '**/*.html', '**/*.vue'],
    css: [{
            raw: 'body { margin: 0 }'
        },
        'css/app.css']
}

But the type definitions have it as compulsory. Which is correct? do I need to add extension: 'css'?

bug

Most helpful comment

This is a mistake in the type definitions, you don't need extension for raw css.
Thanks for reporting this, ill fix it as soon as I can

>All comments

This is a mistake in the type definitions, you don't need extension for raw css.
Thanks for reporting this, ill fix it as soon as I can

Was this page helpful?
0 / 5 - 0 ratings

Related issues

XhmikosR picture XhmikosR  路  9Comments

maartenvanbenthem picture maartenvanbenthem  路  4Comments

TomS- picture TomS-  路  3Comments

Ffloriel picture Ffloriel  路  6Comments

spaceemotion picture spaceemotion  路  4Comments