Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

mini-css-extract-plugin

Package Overview
Dependencies
Maintainers
3
Versions
79
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mini-css-extract-plugin - npm Package Compare versions

Comparing version 2.9.0 to 2.9.1

4

dist/loader.js

@@ -197,2 +197,3 @@ "use strict";

const result = function makeResult() {
const defaultExport = typeof options.defaultExport !== "undefined" ? options.defaultExport : false;
if (locals) {

@@ -209,3 +210,2 @@ if (namedExport) {

const exportsString = `export { ${identifiers.map(([id, key]) => `${id} as ${JSON.stringify(key)}`).join(", ")} }`;
const defaultExport = typeof options.defaultExport !== "undefined" ? options.defaultExport : false;
return defaultExport ? `${localsString}\n${exportsString}\nexport default { ${identifiers.map(([id, key]) => `${JSON.stringify(key)}: ${id}`).join(", ")} }\n` : `${localsString}\n${exportsString}\n`;

@@ -215,3 +215,3 @@ }

} else if (esModule) {
return "\nexport {};";
return defaultExport ? "\nexport {};export default {};" : "\nexport {};";
}

@@ -218,0 +218,0 @@ return "";

{
"name": "mini-css-extract-plugin",
"version": "2.9.0",
"version": "2.9.1",
"description": "extracts CSS into separate files",

@@ -5,0 +5,0 @@ "license": "MIT",

@@ -85,7 +85,7 @@ <div align="center">

> **Warning**
> [!WARNING]
>
> Note that if you import CSS from your webpack entrypoint or import styles in the [initial](https://webpack.js.org/concepts/under-the-hood/#chunks) chunk, `mini-css-extract-plugin` will not load this CSS into the page. Please use [`html-webpack-plugin`](https://github.com/jantimon/html-webpack-plugin) for automatic generation `link` tags or create `index.html` file with `link` tag.
> **Warning**
> [!WARNING]
>

@@ -166,3 +166,3 @@ > Source maps works only for `source-map`/`nosources-source-map`/`hidden-nosources-source-map`/`hidden-source-map` values because CSS only supports source maps with the `sourceMappingURL` comment (i.e. `//# sourceMappingURL=style.css.map`). If you need set `devtool` to another value you can enable source maps generation for extracted CSS using [`sourceMap: true`](https://github.com/webpack-contrib/css-loader#sourcemap) for `css-loader`.

> **Warning**
> [!WARNING]
>

@@ -227,3 +227,3 @@ > Only for [non-initial (async)](https://webpack.js.org/concepts/under-the-hood/#chunks) chunks.

> **Warning**
> [!WARNING]
>

@@ -259,3 +259,3 @@ > Only for [non-initial (async)](https://webpack.js.org/concepts/under-the-hood/#chunks) chunks.

> **Note**
> [!NOTE]
>

@@ -567,3 +567,3 @@ > It's only applied to dynamically loaded css chunks, if you want to modify link attributes inside html file, please using [html-webpack-plugin](https://github.com/jantimon/html-webpack-plugin)

> **Note**
> [!NOTE]
>

@@ -600,5 +600,7 @@ > This option will work only when you set `namedExport` to `true` in `css-loader`

loader: "css-loader",
esModule: true,
modules: {
namedExport: true,
options: {
esModule: true,
modules: {
namedExport: true,
},
},

@@ -839,3 +841,3 @@ },

> **Note**
> [!NOTE]
>

@@ -842,0 +844,0 @@ > HMR is automatically supported in webpack 5. No need to configure it. Skip the following:

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc