@ideasonpurpose/build-tools-wordpress 2.10.8 → 2.10.9
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/README.md +28 -10
- package/boilerplate/package.json +2 -2
- package/package.json +19 -19
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @ideasonpurpose/build-tools-wordpress
|
|
2
2
|
|
|
3
|
-
#### Version 2.10.
|
|
3
|
+
#### Version 2.10.9
|
|
4
4
|
|
|
5
5
|
[](https://www.npmjs.com/package/@ideasonpurpose/build-tools-wordpress)
|
|
6
6
|
[](https://github.com/ideasonpurpose/build-tools-wordpress/actions/workflows/npm-publish.yml)
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
Build scripts and shared dependencies for WordPress development. Used in production at [Ideas On Purpose](https://www.ideasonpurpose.com).
|
|
10
10
|
|
|
11
|
-
This package centralizes Webpack configuration, asset pipelines, and helper CLIs so host projects stay thin: a small `package.json`, a one-line `webpack.config.js`, and an optional config file.
|
|
11
|
+
This package centralizes Webpack configuration, asset pipelines, and helper CLIs so host projects stay fast and thin: a small `package.json`, a one-line `webpack.config.js`, and an optional config file.
|
|
12
|
+
|
|
13
|
+
Use with IOP's lightning-fast [Docker-based WordPress development image](https://github.com/ideasonpurpose/docker-wordpress-dev).
|
|
12
14
|
|
|
13
15
|
## Requirements
|
|
14
16
|
|
|
@@ -46,14 +48,16 @@ Prettier and Stylelint configs are re-exported from this package’s dependencie
|
|
|
46
48
|
|
|
47
49
|
## Quick start
|
|
48
50
|
|
|
49
|
-
|
|
51
|
+
### 1. Point Webpack at this package
|
|
50
52
|
|
|
51
53
|
```js
|
|
52
54
|
// webpack.config.js
|
|
53
55
|
export { webpackConfig as default } from "@ideasonpurpose/build-tools-wordpress";
|
|
54
56
|
```
|
|
55
57
|
|
|
56
|
-
|
|
58
|
+
### 2. Source files
|
|
59
|
+
|
|
60
|
+
The project should have these files:
|
|
57
61
|
|
|
58
62
|
```text
|
|
59
63
|
wp-content/themes/<package-name>/
|
|
@@ -61,18 +65,17 @@ wp-content/themes/<package-name>/
|
|
|
61
65
|
js/main.js
|
|
62
66
|
js/admin.js
|
|
63
67
|
js/editor.js
|
|
64
|
-
|
|
65
|
-
dist/ # build output
|
|
68
|
+
styles/ # formerly 'sass'
|
|
66
69
|
```
|
|
67
70
|
|
|
68
|
-
|
|
71
|
+
### 3. Run
|
|
69
72
|
|
|
70
73
|
```sh
|
|
71
|
-
npm
|
|
72
|
-
|
|
74
|
+
npm run dev
|
|
75
|
+
|
|
73
76
|
```
|
|
74
77
|
|
|
75
|
-
|
|
78
|
+
### 4. Build
|
|
76
79
|
|
|
77
80
|
## Configuration
|
|
78
81
|
|
|
@@ -204,6 +207,21 @@ Notes:
|
|
|
204
207
|
- Custom: remove top-level `fill="none"`
|
|
205
208
|
- `removeUselessStrokeAndFill` with `removeNone: true`
|
|
206
209
|
|
|
210
|
+
## WP-CLI
|
|
211
|
+
|
|
212
|
+
The WordPress base image includes [wp-cli](https://wordpress.org/cli/) and all commands can be run on the image using the `wp-cli` npm script. Commands with flags need to include a double-hyphen, but we just include them for everything. These all work as expected:
|
|
213
|
+
|
|
214
|
+
```sh
|
|
215
|
+
# list users
|
|
216
|
+
npm run wp-cli -- wp user list
|
|
217
|
+
|
|
218
|
+
# Update to pre-release
|
|
219
|
+
npm run wp-cli -- wp core update --version=7.1-RC4
|
|
220
|
+
|
|
221
|
+
# Add a user for e2e testing
|
|
222
|
+
wp user create test test@example.com --role=administrator --user_pass=test123
|
|
223
|
+
```
|
|
224
|
+
|
|
207
225
|
## CLI tools
|
|
208
226
|
|
|
209
227
|
| Command | Purpose |
|
package/boilerplate/package.json
CHANGED
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"version": "version-everything && git add -u",
|
|
56
56
|
"postversion": "npm run build",
|
|
57
57
|
"webgrind": "docker compose run --rm --service-ports webgrind",
|
|
58
|
-
"wp-cli": "docker compose exec
|
|
58
|
+
"wp-cli": "docker compose exec wordpress",
|
|
59
59
|
"zip": "iop-build-zip-archive"
|
|
60
60
|
},
|
|
61
61
|
"prettier": "@ideasonpurpose/prettier-config",
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"extends": "@ideasonpurpose/stylelint-config"
|
|
64
64
|
},
|
|
65
65
|
"devDependencies": {
|
|
66
|
-
"@ideasonpurpose/build-tools-wordpress": "^2.
|
|
66
|
+
"@ideasonpurpose/build-tools-wordpress": "^2.10.8"
|
|
67
67
|
},
|
|
68
68
|
"version-everything": {
|
|
69
69
|
"files": [
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ideasonpurpose/build-tools-wordpress",
|
|
3
|
-
"version": "2.10.
|
|
3
|
+
"version": "2.10.9",
|
|
4
4
|
"description": "Build scripts and dependencies for IOP's WordPress development environments.",
|
|
5
5
|
"homepage": "https://github.com/ideasonpurpose/build-tools-wordpress#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -43,43 +43,43 @@
|
|
|
43
43
|
"@rollup/plugin-json": "^6.1.0",
|
|
44
44
|
"@rollup/plugin-node-resolve": "^16.0.3",
|
|
45
45
|
"@svgr/webpack": "^8.1.0",
|
|
46
|
-
"@wordpress/dependency-extraction-webpack-plugin": "^6.
|
|
46
|
+
"@wordpress/dependency-extraction-webpack-plugin": "^6.53.0",
|
|
47
47
|
"ansi-html": "^0.0.9",
|
|
48
48
|
"archiver": "^8.0.0",
|
|
49
|
-
"autoprefixer": "^10.5.
|
|
49
|
+
"autoprefixer": "^10.5.4",
|
|
50
50
|
"babel-loader": "^10.1.1",
|
|
51
|
-
"caniuse-lite": "^1.0.
|
|
52
|
-
"chalk": "^
|
|
51
|
+
"caniuse-lite": "^1.0.30001809",
|
|
52
|
+
"chalk": "^6.0.0",
|
|
53
53
|
"chalk-cli": "^6.0.0",
|
|
54
54
|
"classnames": "^2.5.1",
|
|
55
55
|
"cli-truncate": "^6.1.1",
|
|
56
56
|
"copy-webpack-plugin": "^14.0.0",
|
|
57
|
-
"cosmiconfig": "^
|
|
57
|
+
"cosmiconfig": "^10.0.0",
|
|
58
58
|
"css-loader": "^7.1.4",
|
|
59
|
-
"cssnano": "^8.0.
|
|
59
|
+
"cssnano": "^8.0.6",
|
|
60
60
|
"dotenv": "^17.4.2",
|
|
61
61
|
"esbuild-loader": "^4.5.0",
|
|
62
|
-
"eslint": "^10.
|
|
62
|
+
"eslint": "^10.8.1",
|
|
63
63
|
"filesize": "^11.0.22",
|
|
64
|
-
"fs-extra": "^11.
|
|
65
|
-
"globby": "^16.2.
|
|
66
|
-
"html-webpack-plugin": "^5.6.
|
|
64
|
+
"fs-extra": "^11.4.0",
|
|
65
|
+
"globby": "^16.2.3",
|
|
66
|
+
"html-webpack-plugin": "^5.6.8",
|
|
67
67
|
"humanize-duration": "^3.34.0",
|
|
68
68
|
"image-minimizer-webpack-plugin": "^5.0.0",
|
|
69
69
|
"is-text-path": "^3.0.0",
|
|
70
70
|
"lodash": "^4.18.1",
|
|
71
71
|
"mini-css-extract-plugin": "^2.10.2",
|
|
72
|
-
"open": "^11.0.
|
|
72
|
+
"open": "^11.0.1",
|
|
73
73
|
"ora": "^9.4.1",
|
|
74
|
-
"postcss": "^8.5.
|
|
74
|
+
"postcss": "^8.5.26",
|
|
75
75
|
"postcss-loader": "^8.2.1",
|
|
76
76
|
"postcss-scss": "^4.0.9",
|
|
77
|
-
"prettier": "^3.9.
|
|
77
|
+
"prettier": "^3.9.6",
|
|
78
78
|
"pretty-hrtime": "^1.0.3",
|
|
79
79
|
"read-package-up": "^12.0.0",
|
|
80
80
|
"replacestream": "^4.0.3",
|
|
81
81
|
"rimraf": "^6.1.3",
|
|
82
|
-
"sass-embedded": "^1.
|
|
82
|
+
"sass-embedded": "^1.102.0",
|
|
83
83
|
"sass-loader": "^17.0.0",
|
|
84
84
|
"semver": "^7.8.5",
|
|
85
85
|
"sharp": "^0.35.3",
|
|
@@ -89,9 +89,9 @@
|
|
|
89
89
|
"svgo": "^4.0.2",
|
|
90
90
|
"svgo-loader": "^5.0.0",
|
|
91
91
|
"version-everything": "^0.12.2",
|
|
92
|
-
"webpack": "^5.
|
|
92
|
+
"webpack": "^5.109.2",
|
|
93
93
|
"webpack-bundle-analyzer": "^5.3.1",
|
|
94
|
-
"webpack-cli": "^
|
|
94
|
+
"webpack-cli": "^7.2.2",
|
|
95
95
|
"webpack-dev-server": "^6.0.0",
|
|
96
96
|
"webpack-manifest-plugin": "^6.0.1"
|
|
97
97
|
},
|
|
@@ -99,8 +99,8 @@
|
|
|
99
99
|
"node": ">=22.15.0"
|
|
100
100
|
},
|
|
101
101
|
"devDependencies": {
|
|
102
|
-
"@vitest/coverage-v8": "^4.1.
|
|
103
|
-
"vitest": "^4.1.
|
|
102
|
+
"@vitest/coverage-v8": "^4.1.11",
|
|
103
|
+
"vitest": "^4.1.11"
|
|
104
104
|
},
|
|
105
105
|
"version-everything": {
|
|
106
106
|
"files": [
|