@flatjs/evolve 1.8.1-next.85 → 1.8.1-next.87
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.md +22 -0
- package/dist/create-webpack/rule-sets/rule-css.js +1 -1
- package/dist/create-webpack/rule-sets/rule-less.js +1 -1
- package/dist/create-webpack/rule-sets/rule-scripts.js +1 -1
- package/dist/helpers/merge-babel-options.js +1 -1
- package/dist/minimizer/image-minimizer.js +1 -1
- package/package.json +27 -27
package/CHANGELOG.md
CHANGED
@@ -1,5 +1,27 @@
|
|
1
1
|
# @flatjs/evolve
|
2
2
|
|
3
|
+
## 1.8.1-next.87
|
4
|
+
|
5
|
+
### Patch Changes
|
6
|
+
|
7
|
+
- 9561920: bump `armit/git`` fix wrong requirements check issue
|
8
|
+
|
9
|
+
## 1.8.1-next.86
|
10
|
+
|
11
|
+
### Patch Changes
|
12
|
+
|
13
|
+
- 2a39933: fix `requireResolve` missed import.meta.url issue
|
14
|
+
- 198037f: bump version
|
15
|
+
- Updated dependencies [1ff347b]
|
16
|
+
- Updated dependencies [2a39933]
|
17
|
+
- Updated dependencies [8513b30]
|
18
|
+
- Updated dependencies [198037f]
|
19
|
+
- @flatjs/mock@1.8.1-next.68
|
20
|
+
- @flatjs/common@1.8.1-next.32
|
21
|
+
- @flatjs/graph@1.8.1-next.45
|
22
|
+
- @flatjs/forge-postcss-plugin-pixel@1.8.1-next.32
|
23
|
+
- @flatjs/evolve-preset-babel@1.8.1-next.16
|
24
|
+
|
3
25
|
## 1.8.1-next.85
|
4
26
|
|
5
27
|
### Patch Changes
|
@@ -1 +1 @@
|
|
1
|
-
import{forgePostcssPluginPixel}from"@flatjs/forge-postcss-plugin-pixel";import cssnano from"cssnano";import MiniCssExtractPlugin from"mini-css-extract-plugin";import{allowPx2remForModule}from"../../helpers/allow-px2rem-for-module.js";const getPostcssOptions=(s,o={},e={})=>{const
|
1
|
+
import{requireResolve}from"@flatjs/common";import{forgePostcssPluginPixel}from"@flatjs/forge-postcss-plugin-pixel";import cssnano from"cssnano";import MiniCssExtractPlugin from"mini-css-extract-plugin";import{allowPx2remForModule}from"../../helpers/allow-px2rem-for-module.js";const getPostcssOptions=(s,o={},e={})=>{const r=[...e.plugins||[],cssnano({preset:["default",{discardComments:{removeAll:!s},reduceInitial:!1,normalizeWhitespace:!s,...e.cssnanoOptions}]})];return!1!==o&&r.push(forgePostcssPluginPixel(o)),{plugins:r}};export const ruleCss=(s,o,e)=>{const{pixelOptions:r,cssLoaderOptions:t,postcssOptions:i}=e.loaderOptions,l={test:/\.css$/i,use:[{loader:MiniCssExtractPlugin.loader,options:{esModule:!0}},{loader:requireResolve(import.meta.url,"css-loader"),options:{sourceMap:s,...t}}]},n=allowPx2remForModule(o,e);if(Array.isArray(l.use)){const o=getPostcssOptions(s,!!n&&r,i);l.use.push({loader:requireResolve(import.meta.url,"postcss-loader"),options:{postcssOptions:{...o,config:!1},sourceMap:s}})}return l};
|
@@ -1 +1 @@
|
|
1
|
-
import{requireResolve}from"@flatjs/common";import{ruleCss}from"./rule-css.js";export const ruleLess=(s,e,r)=>{const o=ruleCss(s,e,r);o.test=/\.less$/i;const
|
1
|
+
import{requireResolve}from"@flatjs/common";import{ruleCss}from"./rule-css.js";export const ruleLess=(s,e,r)=>{const o=ruleCss(s,e,r);o.test=/\.less$/i;const t=r.loaderOptions.lessOptions;return Array.isArray(o.use)&&o.use.push({loader:requireResolve(import.meta.url,"less-loader"),options:{sourceMap:s,lessOptions:{sourceMap:s,javascriptEnabled:!0,...t}}}),o};
|
@@ -1 +1 @@
|
|
1
|
-
import{requireResolve}from"@flatjs/common";import{mergeBabelOption}from"../../helpers/merge-babel-options.js";import{shouldEnableReactFastRefresh}from"../../helpers/should-enable-react-fast-refresh.js";export const ruleScripts=(e,r,s)=>{const{babelOptions:o={},modularImports:
|
1
|
+
import{requireResolve}from"@flatjs/common";import{mergeBabelOption}from"../../helpers/merge-babel-options.js";import{shouldEnableReactFastRefresh}from"../../helpers/should-enable-react-fast-refresh.js";export const ruleScripts=(e,r,s)=>{const{babelOptions:o={},modularImports:t=[]}=s.loaderOptions,l=mergeBabelOption(t,o);shouldEnableReactFastRefresh(e,r,s)&&(l.plugins?l.plugins.push(requireResolve(import.meta.url,"react-refresh/babel")):l.plugins=[requireResolve(import.meta.url,"react-refresh/babel")]);return{test:/\.(tsx|ts|js|jsx)$/,use:[{loader:requireResolve(import.meta.url,"babel-loader"),options:l}]}};
|
@@ -1 +1 @@
|
|
1
|
-
import{logger,requireResolve}from"@flatjs/common";import{reactBabelPreset,vueBabelPreset}from"@flatjs/evolve-preset-babel";import babelMerge from"babel-merge";import{moduleName}from"../constants.js";export const mergeBabelOption=(e=[],r={usePreset:"react"})=>{const t=e.map((e=>[requireResolve("babel-plugin-import"),{transformToDefaultImport:!1,libraryDirectory:"dist",...e},e.libraryName])),{usePreset:a="react",...l}=r,o="react"===a?reactBabelPreset():"vue"===a?vueBabelPreset():reactBabelPreset();let s={};try{s=babelMerge(o,l),s.plugins?s.plugins.unshift(...t):s.plugins=t}catch(e){logger.error(e,moduleName)}return{...s,babelrc:!1,compact:!1}};
|
1
|
+
import{logger,requireResolve}from"@flatjs/common";import{reactBabelPreset,vueBabelPreset}from"@flatjs/evolve-preset-babel";import babelMerge from"babel-merge";import{moduleName}from"../constants.js";export const mergeBabelOption=(e=[],r={usePreset:"react"})=>{const t=e.map((e=>[requireResolve(import.meta.url,"babel-plugin-import"),{transformToDefaultImport:!1,libraryDirectory:"dist",...e},e.libraryName])),{usePreset:a="react",...l}=r,o="react"===a?reactBabelPreset():"vue"===a?vueBabelPreset():reactBabelPreset();let s={};try{s=babelMerge(o,l),s.plugins?s.plugins.unshift(...t):s.plugins=t}catch(e){logger.error(e,moduleName)}return{...s,babelrc:!1,compact:!1}};
|
@@ -1 +1 @@
|
|
1
|
-
import{projectHasYarn}from"@armit/package";import{chalk,logger,requireResolve}from"@flatjs/common";import ImageMinimizerPlugin from"image-minimizer-webpack-plugin";import{moduleName}from"../constants.js";const logs=new Map;export const imageMinimizer=()=>{const e=[],i=[["svgo",{}],["gifsicle",{}],["jpegtran",{}],["pngquant",{}]].map((i=>{const n=i[0];try{return requireResolve(
|
1
|
+
import{projectHasYarn}from"@armit/package";import{chalk,logger,requireResolve}from"@flatjs/common";import ImageMinimizerPlugin from"image-minimizer-webpack-plugin";import{moduleName}from"../constants.js";const logs=new Map;export const imageMinimizer=()=>{const e=[],i=[["svgo",{}],["gifsicle",{}],["jpegtran",{}],["pngquant",{}]].map((i=>{const n=i[0];try{return requireResolve(import.meta.url,`imagemin-${n}`),i}catch(i){if(!logs.get(n)){logs.set(n,!0);const i=chalk(["magenta"])(`"${projectHasYarn()?"yarn add":"npm install"} imagemin-${n} -D"`);e.push(`Execute ${i} for assets optimization`)}return null}})).filter(Boolean);if(e.length)for(const i of e)logger.warn(i,moduleName);return i.length?new ImageMinimizerPlugin({minimizer:{implementation:ImageMinimizerPlugin.imageminMinify,options:{plugins:i}}}):null};
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@flatjs/evolve",
|
3
|
-
"version": "1.8.1-next.
|
3
|
+
"version": "1.8.1-next.87",
|
4
4
|
"license": "MIT",
|
5
5
|
"type": "module",
|
6
6
|
"exports": {
|
@@ -37,20 +37,20 @@
|
|
37
37
|
"typecheck": "tsc --project ./tsconfig.json --noEmit"
|
38
38
|
},
|
39
39
|
"dependencies": {
|
40
|
-
"@armit/config-loader": "^0.0.
|
41
|
-
"@armit/file-utility": "^0.0.
|
42
|
-
"@armit/git": "^0.0.
|
43
|
-
"@armit/package": "^0.0.
|
44
|
-
"@armit/worker-threads": "^0.0.
|
45
|
-
"@babel/core": "7.22.
|
46
|
-
"@flatjs/common": "1.8.1-next.
|
47
|
-
"@flatjs/evolve-preset-babel": "1.8.1-next.
|
48
|
-
"@flatjs/forge-postcss-plugin-pixel": "1.8.1-next.
|
49
|
-
"@flatjs/graph": "1.8.1-next.
|
50
|
-
"@flatjs/mock": "1.8.1-next.
|
40
|
+
"@armit/config-loader": "^0.0.48",
|
41
|
+
"@armit/file-utility": "^0.0.27",
|
42
|
+
"@armit/git": "^0.0.34",
|
43
|
+
"@armit/package": "^0.0.42",
|
44
|
+
"@armit/worker-threads": "^0.0.4",
|
45
|
+
"@babel/core": "7.22.9",
|
46
|
+
"@flatjs/common": "1.8.1-next.32",
|
47
|
+
"@flatjs/evolve-preset-babel": "1.8.1-next.16",
|
48
|
+
"@flatjs/forge-postcss-plugin-pixel": "1.8.1-next.32",
|
49
|
+
"@flatjs/graph": "1.8.1-next.45",
|
50
|
+
"@flatjs/mock": "1.8.1-next.68",
|
51
51
|
"@pmmmwh/react-refresh-webpack-plugin": "0.5.10",
|
52
52
|
"@types/babel__core": "7.20.1",
|
53
|
-
"babel-loader": "9.1.
|
53
|
+
"babel-loader": "9.1.3",
|
54
54
|
"babel-merge": "3.0.0",
|
55
55
|
"babel-plugin-import": "1.13.6",
|
56
56
|
"better-opn": "3.0.2",
|
@@ -59,7 +59,7 @@
|
|
59
59
|
"cssnano": "6.0.1",
|
60
60
|
"express": "4.18.2",
|
61
61
|
"fork-ts-checker-webpack-plugin": "8.0.0",
|
62
|
-
"happy-dom": "
|
62
|
+
"happy-dom": "10.5.2",
|
63
63
|
"html-webpack-plugin": "5.5.3",
|
64
64
|
"image-minimizer-webpack-plugin": "3.8.3",
|
65
65
|
"less": "4.1.3",
|
@@ -67,40 +67,40 @@
|
|
67
67
|
"listr": "0.14.3",
|
68
68
|
"lodash": "4.17.21",
|
69
69
|
"mini-css-extract-plugin": "2.7.6",
|
70
|
-
"postcss": "8.4.
|
70
|
+
"postcss": "8.4.27",
|
71
71
|
"postcss-loader": "7.3.3",
|
72
72
|
"react-refresh": "0.14.0",
|
73
73
|
"svgo": "3.0.2",
|
74
74
|
"terser-webpack-plugin": "5.3.9",
|
75
|
-
"tsconfig-paths-webpack-plugin": "4.0
|
76
|
-
"type-fest": "^
|
77
|
-
"webpack": "5.88.
|
75
|
+
"tsconfig-paths-webpack-plugin": "4.1.0",
|
76
|
+
"type-fest": "^4.0.0",
|
77
|
+
"webpack": "5.88.2",
|
78
78
|
"webpack-bundle-analyzer": "4.9.0",
|
79
79
|
"webpack-dev-server": "4.15.1",
|
80
80
|
"webpack-sources": "3.2.3"
|
81
81
|
},
|
82
82
|
"devDependencies": {
|
83
|
-
"@armit/eslint-config-bases": "^0.0.
|
84
|
-
"@flatjs/testing": "1.8.1-next.
|
85
|
-
"@swc/core": "1.3.
|
83
|
+
"@armit/eslint-config-bases": "^0.0.22",
|
84
|
+
"@flatjs/testing": "1.8.1-next.33",
|
85
|
+
"@swc/core": "1.3.70",
|
86
86
|
"@types/express": "4.17.17",
|
87
87
|
"@types/listr": "0.14.4",
|
88
|
-
"@types/node": "20.
|
89
|
-
"@vitest/coverage-istanbul": "0.
|
90
|
-
"@vitest/ui": "0.
|
91
|
-
"eslint": "8.
|
88
|
+
"@types/node": "20.4.4",
|
89
|
+
"@vitest/coverage-istanbul": "0.33.0",
|
90
|
+
"@vitest/ui": "0.33.0",
|
91
|
+
"eslint": "8.45.0",
|
92
92
|
"imagemin-gifsicle": "7.0.0",
|
93
93
|
"imagemin-jpegtran": "7.0.0",
|
94
94
|
"imagemin-pngquant": "9.0.2",
|
95
95
|
"imagemin-svgo": "10.0.1",
|
96
96
|
"npm-run-all": "4.1.5",
|
97
|
-
"prettier": "
|
97
|
+
"prettier": "3.0.0",
|
98
98
|
"react": "18.2.0",
|
99
99
|
"rimraf": "5.0.1",
|
100
100
|
"swc-unplugin-ts": "1.0.2",
|
101
101
|
"ts-node": "10.9.1",
|
102
102
|
"vite-tsconfig-paths": "4.2.0",
|
103
|
-
"vitest": "0.
|
103
|
+
"vitest": "0.33.0",
|
104
104
|
"vue-loader": "17.2.2"
|
105
105
|
},
|
106
106
|
"peerDependencies": {
|