Skip to content

Releases: tivac/modular-css

@modular-css/[email protected]

14 Feb 21:14
33b1831
Compare
Choose a tag to compare

Minor Changes

  • #1040 17b6ae2 Thanks @tivac! - ## CSS coverage & warnings on unused classes

    Added dev.warn and dev.coverage as supported options for @modular-css/css-to-js package, and by extension @modular-css/rollup, @modular-css/vite, and @modular-css/webpack.

    dev.warn will cause unknown classes requested from JS to log a warning to the console, instead of the current errors that are thrown.

    dev.coverage will cause a global named mcssCoverage to be created which will track accesses of all exported classes per file and allow you to identify unused styles.

    Example of a mcssCoverage object

    {
        "packages/vite/tests/specimens/shared/static-c.mcss" : { c : 0 },
        "packages/vite/tests/specimens/static/a.mcss" : { a : 1 },
        "packages/vite/tests/specimens/static/b.mcss" : { b : 1 },
    }

Patch Changes

@modular-css/[email protected]

14 Feb 21:14
33b1831
Compare
Choose a tag to compare

Minor Changes

  • #1040 17b6ae2 Thanks @tivac! - ## CSS coverage & warnings on unused classes

    Added dev.warn and dev.coverage as supported options for @modular-css/css-to-js package, and by extension @modular-css/rollup, @modular-css/vite, and @modular-css/webpack.

    dev.warn will cause unknown classes requested from JS to log a warning to the console, instead of the current errors that are thrown.

    dev.coverage will cause a global named mcssCoverage to be created which will track accesses of all exported classes per file and allow you to identify unused styles.

    Example of a mcssCoverage object

    {
        "packages/vite/tests/specimens/shared/static-c.mcss" : { c : 0 },
        "packages/vite/tests/specimens/static/a.mcss" : { a : 1 },
        "packages/vite/tests/specimens/static/b.mcss" : { b : 1 },
    }

Patch Changes

@modular-css/[email protected]

14 Feb 21:14
33b1831
Compare
Choose a tag to compare

Minor Changes

  • #1040 17b6ae2 Thanks @tivac! - ## CSS coverage & warnings on unused classes

    Added dev.warn and dev.coverage as supported options for @modular-css/css-to-js package, and by extension @modular-css/rollup, @modular-css/vite, and @modular-css/webpack.

    dev.warn will cause unknown classes requested from JS to log a warning to the console, instead of the current errors that are thrown.

    dev.coverage will cause a global named mcssCoverage to be created which will track accesses of all exported classes per file and allow you to identify unused styles.

    Example of a mcssCoverage object

    {
        "packages/vite/tests/specimens/shared/static-c.mcss" : { c : 0 },
        "packages/vite/tests/specimens/static/a.mcss" : { a : 1 },
        "packages/vite/tests/specimens/static/b.mcss" : { b : 1 },
    }

Patch Changes

@modular-css/[email protected]

14 Feb 21:14
33b1831
Compare
Choose a tag to compare

Minor Changes

  • #1040 17b6ae2 Thanks @tivac! - ## CSS coverage & warnings on unused classes

    Added dev.warn and dev.coverage as supported options for @modular-css/css-to-js package, and by extension @modular-css/rollup, @modular-css/vite, and @modular-css/webpack.

    dev.warn will cause unknown classes requested from JS to log a warning to the console, instead of the current errors that are thrown.

    dev.coverage will cause a global named mcssCoverage to be created which will track accesses of all exported classes per file and allow you to identify unused styles.

    Example of a mcssCoverage object

    {
        "packages/vite/tests/specimens/shared/static-c.mcss" : { c : 0 },
        "packages/vite/tests/specimens/static/a.mcss" : { a : 1 },
        "packages/vite/tests/specimens/static/b.mcss" : { b : 1 },
    }

@modular-css/[email protected]

21 Jan 18:14
c9fb450
Compare
Choose a tag to compare

Patch Changes

@modular-css/[email protected]

18 Jan 01:08
3ce75cd
Compare
Choose a tag to compare

Minor Changes

@modular-css/[email protected]

10 Jan 20:33
94150f1
Compare
Choose a tag to compare

Patch Changes

@modular-css/[email protected]

10 Jan 20:33
94150f1
Compare
Choose a tag to compare

Patch Changes

@modular-css/[email protected]

10 Jan 20:33
94150f1
Compare
Choose a tag to compare

Patch Changes

@modular-css/[email protected]

10 Jan 20:33
94150f1
Compare
Choose a tag to compare

Patch Changes