Skip to content

Css in autocomplete-theme-classic removed by Webpack due to sideEffects false? #586

@joakimriedel

Description

@joakimriedel

Description

I'm experimenting with the Autocomplete in a project that uses Webpack 5 as bundling tool. When following the getting started guide, and importing the default theme like this...

import '@algolia/autocomplete-theme-classic';

... it seems as if the contained css won't be included in the final bundle.

Researching a bit shows that this could possibly be due to the sideEffects setting being false in package.json of https://github.com/algolia/autocomplete/blob/next/packages/autocomplete-theme-classic/package.json ?

See https://webpack.js.org/guides/tree-shaking/#clarifying-tree-shaking-and-sideeffects

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions