@plaudit/webpack-extensions 2.97.0 → 2.98.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.
- package/CHANGELOG.md +4 -0
- package/dist/shared.d.ts +11 -11
- package/dist/utils/location-encoding-filename-parser.d.ts +4 -4
- package/dist/wordpress-ports/dependency-extraction-webpack-plugin/index.d.ts +1 -1
- package/dist/wordpress-ports/dependency-extraction-webpack-plugin/index.js +1 -5
- package/dist/wordpress-ports/dependency-extraction-webpack-plugin/util.js +1 -0
- package/dist/wordpress-scripts-wrapper.d.ts +1 -1
- package/package.json +7 -7
package/CHANGELOG.md
CHANGED
|
@@ -60,6 +60,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
60
60
|
- Legacy PostCSS features that have been integrated into modern CSS
|
|
61
61
|
- `@extends` support
|
|
62
62
|
|
|
63
|
+
## [2.98.0] - 2026-08-18
|
|
64
|
+
### Added
|
|
65
|
+
- Automatic sync of WordPress's bundled packages list
|
|
66
|
+
|
|
63
67
|
## [2.97.0] - 2026-08-18
|
|
64
68
|
### Added
|
|
65
69
|
- David's improvements to build pipeline efficiency
|
package/dist/shared.d.ts
CHANGED
|
@@ -163,29 +163,29 @@ export declare function shouldWriteDistDev(config: Pick<PlauditWordpressWebpackC
|
|
|
163
163
|
*/
|
|
164
164
|
export declare function isDistDevOutputPath(outputPath: string): boolean;
|
|
165
165
|
export declare function applyStandards(config: PlauditWordpressWebpackConfig): {
|
|
166
|
-
readonly standard?:
|
|
166
|
+
readonly standard?: '2026-03-13';
|
|
167
167
|
readonly standaloneBlocks?: boolean;
|
|
168
168
|
readonly variables?: Record<string, any>;
|
|
169
169
|
readonly verbose?: boolean;
|
|
170
170
|
readonly src?: string[] | SourcesObject;
|
|
171
|
-
readonly stats?: Configuration[
|
|
171
|
+
readonly stats?: Configuration['stats'];
|
|
172
172
|
readonly postcss?: {
|
|
173
|
-
functions?: (variables: (name: string) => unknown) => PostcssFunctionsOptions[
|
|
173
|
+
functions?: (variables: (name: string) => unknown) => PostcssFunctionsOptions['functions'];
|
|
174
174
|
};
|
|
175
175
|
readonly externals?: Externals;
|
|
176
176
|
readonly assumeGlobalizedPlauditLibraries?: boolean;
|
|
177
|
-
useWebpackResourceFiltering?: boolean;
|
|
178
|
-
outputDir?: string;
|
|
179
|
-
extensionsVersion?: 1 | 2 | 3;
|
|
180
177
|
readonly targetHandlePrefix?: string;
|
|
181
|
-
plainEntrypointsVersion?: 1 | 2;
|
|
182
|
-
srcDir?: string;
|
|
183
178
|
readonly srcPrefixes?: string[];
|
|
184
|
-
useUnifiedLoader?: boolean;
|
|
185
179
|
readonly includePostInitFallback?: boolean;
|
|
186
180
|
readonly omitDistDev?: boolean;
|
|
187
|
-
onlyRunPostCSSOnPCSS?: boolean;
|
|
188
181
|
readonly useBlockSupportsAsThemeJsonDefaults?: boolean;
|
|
182
|
+
useWebpackResourceFiltering?: boolean | undefined;
|
|
183
|
+
extensionsVersion?: 1 | 2 | 3 | undefined;
|
|
184
|
+
plainEntrypointsVersion?: 1 | 2 | undefined;
|
|
185
|
+
srcDir?: string | undefined;
|
|
186
|
+
outputDir?: string | undefined;
|
|
187
|
+
useUnifiedLoader?: boolean | undefined;
|
|
188
|
+
onlyRunPostCSSOnPCSS?: boolean | undefined;
|
|
189
189
|
};
|
|
190
190
|
export declare function resolveStandard(standard: PlauditWordpressWebpackConfig['standard']): {
|
|
191
191
|
readonly useWebpackResourceFiltering: true;
|
|
@@ -228,7 +228,7 @@ export declare const scriptExtension: RegExp;
|
|
|
228
228
|
export declare const scriptWithoutModuleExtension: RegExp;
|
|
229
229
|
export declare const scriptWithModuleExtension: RegExp;
|
|
230
230
|
export declare const styleExtension: RegExp;
|
|
231
|
-
export declare function scriptOrStyleTest(entryPath: string, scriptExtension: RegExp): "
|
|
231
|
+
export declare function scriptOrStyleTest(entryPath: string, scriptExtension: RegExp): "" | "script" | "style";
|
|
232
232
|
export declare function isStyleField(field: string): field is 'style' | 'viewStyle' | 'editorStyle';
|
|
233
233
|
export declare function isScriptModuleField(field: string): field is 'viewScriptModule';
|
|
234
234
|
export declare function mergeModuleDependencyArrays(a: WPModuleDependency[] | undefined, b: WPModuleDependency[] | undefined): WPModuleDependency[] | undefined;
|
|
@@ -9,18 +9,18 @@ export type ParsedLocationEncodingFilename = {
|
|
|
9
9
|
niceName?: string;
|
|
10
10
|
};
|
|
11
11
|
export declare function parseLocationEncodingFilename(filename: string): ParsedLocationEncodingFilename | undefined;
|
|
12
|
-
export declare function parseLocationEncodingFilenameForBlock(filename: string, errorBuilder?: (message: string, filename: string) => unknown): Omit<ParsedLocationEncodingFilename, 'locations'> & {
|
|
12
|
+
export declare function parseLocationEncodingFilenameForBlock(filename: string, errorBuilder?: (message: string, filename: string) => unknown): (Omit<ParsedLocationEncodingFilename, 'locations'> & {
|
|
13
13
|
locations: Pick<RealUsageLocations, 'clientEditor' | 'clientView'>;
|
|
14
|
-
} | undefined;
|
|
14
|
+
}) | undefined;
|
|
15
15
|
/**
|
|
16
16
|
* This handles detecting all keys of standardLocationNamesMeta as well as "view", "client-view", "editor", "client-editor", and "block-assets".
|
|
17
17
|
* It MUST be kept in sync with standardLocationNamesMeta
|
|
18
18
|
* @param segment
|
|
19
19
|
*/
|
|
20
20
|
export declare function extractLocationFromPropertyEncodingFilenameSegment(segment: string): {
|
|
21
|
-
readonly locationName: "
|
|
21
|
+
readonly locationName: "admin" | "analytics" | "blockAssets" | "clientEditor" | "clientView" | "customizer" | "login" | "register";
|
|
22
22
|
readonly priority: number | true;
|
|
23
23
|
} | {
|
|
24
|
-
readonly locationName: false;
|
|
25
24
|
readonly priority?: undefined;
|
|
25
|
+
readonly locationName: false;
|
|
26
26
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import LegacyDependencyExtractionWebpackPlugin from "@wordpress/dependency-extraction-webpack-plugin";
|
|
1
|
+
import type LegacyDependencyExtractionWebpackPlugin from "@wordpress/dependency-extraction-webpack-plugin";
|
|
2
2
|
import { Compilation, Compiler, Module, type TemplatePath } from "webpack";
|
|
3
3
|
export interface EnhancedDependencyExtractionWebpackPluginOptions {
|
|
4
4
|
injectPolyfill?: boolean;
|
|
@@ -1,10 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.EnhancedDependencyExtractionWebpackPlugin = void 0;
|
|
7
|
-
const dependency_extraction_webpack_plugin_1 = __importDefault(require("@wordpress/dependency-extraction-webpack-plugin"));
|
|
8
4
|
const webpack_1 = require("webpack");
|
|
9
5
|
/**
|
|
10
6
|
* Internal dependencies
|
|
@@ -34,7 +30,7 @@ class EnhancedDependencyExtractionWebpackPlugin {
|
|
|
34
30
|
*/
|
|
35
31
|
useModules = false;
|
|
36
32
|
constructor(options) {
|
|
37
|
-
if (options
|
|
33
|
+
if (typeof options === 'object' && options?.constructor?.name === 'DependencyExtractionWebpackPlugin') {
|
|
38
34
|
options = options.options;
|
|
39
35
|
}
|
|
40
36
|
if (options instanceof EnhancedDependencyExtractionWebpackPlugin) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { PlauditWordpressWebpackConfig } from "./shared";
|
|
2
2
|
import type { Configuration } from "webpack";
|
|
3
|
-
declare const _default: (config: PlauditWordpressWebpackConfig, webpackConfig?: Configuration[] | Configuration) => Configuration[];
|
|
4
3
|
export = _default;
|
|
4
|
+
declare function _default(config: PlauditWordpressWebpackConfig, webpackConfig?: Configuration[] | Configuration): Configuration[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@plaudit/webpack-extensions",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.98.0",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -34,11 +34,12 @@
|
|
|
34
34
|
"devDependencies": {
|
|
35
35
|
"@plaudit/dev-webpack-plugin": "^1.0.1",
|
|
36
36
|
"@plaudit/gutenberg-api-extensions": "^2.98.2",
|
|
37
|
-
"@types/jsdom": "^
|
|
38
|
-
"@types/node": "^
|
|
37
|
+
"@types/jsdom": "^30.0.0",
|
|
38
|
+
"@types/node": "^26.2.0",
|
|
39
39
|
"@types/postcss-functions": "^4.0.4",
|
|
40
40
|
"@types/tapable": "^2.3.0",
|
|
41
41
|
"@types/webpack-sources": "^3.2.3",
|
|
42
|
+
"@wordpress/dependency-extraction-webpack-plugin": "^6.53.0",
|
|
42
43
|
"atob": "^2.1.2",
|
|
43
44
|
"css-loader": "^6.11.0",
|
|
44
45
|
"glob": "^7.2.3",
|
|
@@ -47,7 +48,7 @@
|
|
|
47
48
|
"mini-css-extract-plugin": "^2.10.2",
|
|
48
49
|
"mkdirp": "^3.0.1",
|
|
49
50
|
"rimraf": "^5.0.10",
|
|
50
|
-
"typescript": "^
|
|
51
|
+
"typescript": "^7.0.2",
|
|
51
52
|
"webpack-bundle-analyzer": "^4.10.2"
|
|
52
53
|
},
|
|
53
54
|
"dependencies": {
|
|
@@ -57,15 +58,13 @@
|
|
|
57
58
|
"@plaudit/postcss-silent-extend": "^3.0.0",
|
|
58
59
|
"@plaudit/postcss-strip-units": "^3.0.0",
|
|
59
60
|
"@plaudit/postcss-variables": "^1.1.0",
|
|
60
|
-
"@wordpress/dependency-extraction-webpack-plugin": "^6.53.0",
|
|
61
61
|
"@wordpress/scripts": "^32.6.0",
|
|
62
62
|
"autoprefixer": "^10.5.4",
|
|
63
63
|
"copy-webpack-plugin": "10.2.4",
|
|
64
64
|
"css-minimizer-webpack-plugin": "^6.0.0",
|
|
65
65
|
"cssnano": "^6.1.2",
|
|
66
66
|
"fork-ts-checker-webpack-plugin": "^9.1.0",
|
|
67
|
-
"
|
|
68
|
-
"jsdom": "^29.1.1",
|
|
67
|
+
"jsdom": "^30.0.1",
|
|
69
68
|
"json2php": "0.0.12",
|
|
70
69
|
"postcss": "^8.5.26",
|
|
71
70
|
"postcss-calc": "^9.0.1",
|
|
@@ -100,6 +99,7 @@
|
|
|
100
99
|
"build": "tsc",
|
|
101
100
|
"clean": "rm -rf dist",
|
|
102
101
|
"build:clean": "pnpm run clean && pnpm run build",
|
|
102
|
+
"build:sync-wp-bundled-packages": "node tools/bundled-packages-sync.mts",
|
|
103
103
|
"watch": "tsc -w",
|
|
104
104
|
"test": "pnpm run build && pnpm run test:no-build",
|
|
105
105
|
"test:no-build": "rm -rf tests/.tmp/coverage/jest && NODE_V8_COVERAGE=tests/.tmp/coverage/jest jest",
|