wp-blank-scripts 3.1.17 → 3.1.18
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "wp-blank-scripts",
|
|
3
|
-
"version": "3.1.
|
|
3
|
+
"version": "3.1.18",
|
|
4
4
|
"description": "Personal Wordpress Scripts",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"bin": {
|
|
@@ -69,9 +69,8 @@
|
|
|
69
69
|
"replace-in-file": "^7.0.1",
|
|
70
70
|
"rimraf": "^5.0.5",
|
|
71
71
|
"rsync": "^0.6.1",
|
|
72
|
-
"sass": "^1.
|
|
73
|
-
"sass-loader": "
|
|
74
|
-
"sass-resources-loader": "^2.2.5",
|
|
72
|
+
"sass": "^1.97.3",
|
|
73
|
+
"sass-loader": "16.0.7",
|
|
75
74
|
"semver": "^7.5.2",
|
|
76
75
|
"slugify": "^1.6.6",
|
|
77
76
|
"ssh2": "0.8.9",
|
package/webpack.base.config.js
CHANGED
package/webpack.react.config.js
CHANGED
|
@@ -19,6 +19,9 @@ function makeReactWebpackConfig(options) {
|
|
|
19
19
|
const sourcePath = path.join(process.cwd(), sourceDir);
|
|
20
20
|
const entryPath = [path.join(sourcePath, 'index.js')];
|
|
21
21
|
const globalVariablesPath = path.join(sourcePath, 'variables.scss');
|
|
22
|
+
const globalVariables = fs.existsSync(globalVariablesPath)
|
|
23
|
+
? fs.readFileSync(globalVariablesPath, 'utf8') + '\n'
|
|
24
|
+
: '';
|
|
22
25
|
|
|
23
26
|
const settings = getSettings();
|
|
24
27
|
const themeDir = path.join('wp-content', 'themes', settings.project);
|
|
@@ -133,12 +136,8 @@ function makeReactWebpackConfig(options) {
|
|
|
133
136
|
loader: 'sass-loader',
|
|
134
137
|
options: {
|
|
135
138
|
sourceMap: !isProd,
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
{
|
|
139
|
-
loader: 'sass-resources-loader',
|
|
140
|
-
options: {
|
|
141
|
-
resources: globalVariablesPath,
|
|
139
|
+
api: 'modern',
|
|
140
|
+
additionalData: globalVariables || undefined,
|
|
142
141
|
},
|
|
143
142
|
},
|
|
144
143
|
],
|