Skip to content

Misleading webpack configuration #30

@herrvigg

Description

@herrvigg

Documentation Is:

  • Missing
  • Needed
  • Confusing
  • Not Sure?

Please Explain in Detail...

I don't think it's a good suggestion to define the webpack configuration as such:

  optimization: {
    minimize: true,
    minimizer: [new CssMinimizerPlugin()],
  },

Problem: the default JS minimizer (Terser) will not be invoked anymore and i don't know how to invoke it without installing it explicitly... It goes against common sense to disable a much wanted behavior especially since this plugin is also about minimization.

Your Proposal for Changes

It seems enough to instantiate an object like this:

    plugins: [
        new CssMinimizerPlugin()
    ]

Like this you don't need to touch the list of minimizers in the optimization entry and you can still have any other plugin in this list.

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