@nuxt/webpack-builder 3.12.4 → 3.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +1 -1
  2. package/dist/index.mjs +10 -4
  3. package/package.json +13 -13
package/README.md CHANGED
@@ -109,7 +109,7 @@ Follow the docs to [Set Up Your Local Development Environment](https://nuxt.com/
109
109
  ## <a name="follow-us">🔗 Follow Us</a>
110
110
 
111
111
  <p valign="center">
112
- <a href="https://chat.nuxt.dev"><img width="20px" src="https://github.com/nuxt/nuxt/tree/main/.github/assets/discord.svg" alt="Discord"></a>&nbsp;&nbsp;<a href="https://twitter.nuxt.dev"><img width="20px" src="https://github.com/nuxt/nuxt/tree/main/.github/assets/twitter.svg" alt="Twitter"></a>&nbsp;&nbsp;<a href="https://github.nuxt.dev"><img width="20px" src="https://github.com/nuxt/nuxt/tree/main/.github/assets/github.svg" alt="GitHub"></a>
112
+ <a href="https://go.nuxt.com/discord"><img width="20px" src="https://github.com/nuxt/nuxt/tree/main/.github/assets/discord.svg" alt="Discord"></a>&nbsp;&nbsp;<a href="https://go.nuxt.com/x"><img width="20px" src="https://github.com/nuxt/nuxt/tree/main/.github/assets/twitter.svg" alt="Twitter"></a>&nbsp;&nbsp;<a href="https://go.nuxt.com/github"><img width="20px" src="https://github.com/nuxt/nuxt/tree/main/.github/assets/github.svg" alt="GitHub"></a>
113
113
  </p>
114
114
 
115
115
  ## <a name="license">⚖️ License</a>
package/dist/index.mjs CHANGED
@@ -5,7 +5,7 @@ import webpackDevMiddleware from 'webpack-dev-middleware';
5
5
  import webpackHotMiddleware from 'webpack-hot-middleware';
6
6
  import { defu } from 'defu';
7
7
  import { parseURL, parseQuery, joinURL } from 'ufo';
8
- import { useNuxt, logger, tryResolveModule, requireModule } from '@nuxt/kit';
8
+ import { useNuxt, logger, resolveAlias, tryResolveModule, requireModule } from '@nuxt/kit';
9
9
  import { pathToFileURL, fileURLToPath } from 'node:url';
10
10
  import { createUnplugin } from 'unplugin';
11
11
  import { isAbsolute, relative, join, resolve, normalize, dirname } from 'pathe';
@@ -728,13 +728,19 @@ async function getPostcssConfig(nuxt) {
728
728
  if (!pluginOptions) {
729
729
  continue;
730
730
  }
731
- const path = await tryResolveModule(pluginName, nuxt.options.modulesDir);
731
+ let pluginPath = resolveAlias(pluginName, nuxt.options.alias);
732
732
  let pluginFn;
733
+ if (pluginPath[0] === ".") {
734
+ pluginPath = resolve(nuxt.options.rootDir, pluginPath);
735
+ }
736
+ const path = await tryResolveModule(pluginPath, nuxt.options.modulesDir);
733
737
  if (path) {
734
738
  pluginFn = await import(pathToFileURL(path).href).then(interopDefault);
735
739
  } else {
736
- console.warn(`[nuxt] could not import postcss plugin \`${pluginName}\` with ESM. Please report this as a bug.`);
737
- pluginFn = requireModule(pluginName, { paths: [cwd] });
740
+ if (!isAbsolute(pluginPath)) {
741
+ console.warn(`[nuxt] could not import postcss plugin \`${pluginName}\` with ESM. Please report this as a bug.`);
742
+ }
743
+ pluginFn = requireModule(pluginPath, { paths: [cwd] });
738
744
  }
739
745
  if (typeof pluginFn === "function") {
740
746
  plugins.push(pluginFn(pluginOptions));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nuxt/webpack-builder",
3
- "version": "3.12.4",
3
+ "version": "3.13.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/nuxt/nuxt.git",
@@ -23,10 +23,10 @@
23
23
  ],
24
24
  "dependencies": {
25
25
  "@nuxt/friendly-errors-webpack-plugin": "^2.6.0",
26
- "autoprefixer": "^10.4.19",
26
+ "autoprefixer": "^10.4.20",
27
27
  "css-loader": "^7.1.2",
28
28
  "css-minimizer-webpack-plugin": "^7.0.0",
29
- "cssnano": "^7.0.4",
29
+ "cssnano": "^7.0.5",
30
30
  "defu": "^6.1.4",
31
31
  "esbuild-loader": "^4.2.2",
32
32
  "escape-string-regexp": "^5.0.0",
@@ -36,14 +36,14 @@
36
36
  "h3": "^1.12.0",
37
37
  "hash-sum": "^2.0.0",
38
38
  "lodash-es": "4.17.21",
39
- "magic-string": "^0.30.10",
40
- "memfs": "^4.9.3",
41
- "mini-css-extract-plugin": "^2.9.0",
39
+ "magic-string": "^0.30.11",
40
+ "memfs": "^4.11.1",
41
+ "mini-css-extract-plugin": "^2.9.1",
42
42
  "mlly": "^1.7.1",
43
43
  "ohash": "^1.1.3",
44
44
  "pathe": "^1.1.2",
45
45
  "pify": "^6.1.0",
46
- "postcss": "^8.4.39",
46
+ "postcss": "^8.4.41",
47
47
  "postcss-import": "^16.1.0",
48
48
  "postcss-import-resolver": "^2.0.0",
49
49
  "postcss-loader": "^8.1.1",
@@ -53,17 +53,17 @@
53
53
  "time-fix-plugin": "^2.0.7",
54
54
  "ufo": "^1.5.4",
55
55
  "unenv": "^1.10.0",
56
- "unplugin": "^1.11.0",
56
+ "unplugin": "^1.12.2",
57
57
  "url-loader": "^4.1.1",
58
58
  "vue-bundle-renderer": "^2.1.0",
59
59
  "vue-loader": "^17.4.2",
60
- "webpack": "^5.93.0",
60
+ "webpack": "^5.94.0",
61
61
  "webpack-bundle-analyzer": "^4.10.2",
62
- "webpack-dev-middleware": "^7.3.0",
62
+ "webpack-dev-middleware": "^7.4.2",
63
63
  "webpack-hot-middleware": "^2.26.1",
64
64
  "webpack-virtual-modules": "^0.6.2",
65
65
  "webpackbar": "^6.0.1",
66
- "@nuxt/kit": "3.12.4"
66
+ "@nuxt/kit": "3.13.0"
67
67
  },
68
68
  "devDependencies": {
69
69
  "@types/hash-sum": "1.0.2",
@@ -72,8 +72,8 @@
72
72
  "@types/webpack-bundle-analyzer": "4.7.0",
73
73
  "@types/webpack-hot-middleware": "2.25.9",
74
74
  "unbuild": "latest",
75
- "vue": "3.4.32",
76
- "@nuxt/schema": "3.12.4"
75
+ "vue": "3.4.38",
76
+ "@nuxt/schema": "3.13.0"
77
77
  },
78
78
  "peerDependencies": {
79
79
  "vue": "^3.3.4"