@modern-js/uni-builder 2.62.0 → 2.63.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.
@@ -88,6 +88,7 @@ async function parseCommonConfig(uniBuilderConfig, options) {
88
88
  output: {
89
89
  polyfill: polyfill === "ua" ? "off" : polyfill,
90
90
  dataUriLimit,
91
+ sourceMap,
91
92
  ...outputConfig
92
93
  },
93
94
  source: {
@@ -127,7 +128,7 @@ async function parseCommonConfig(uniBuilderConfig, options) {
127
128
  (_output3 = output).cssModules || (_output3.cssModules = {});
128
129
  output.cssModules.localIdentName = cssModuleLocalIdentName;
129
130
  }
130
- if (isUseCssSourceMap(disableSourceMap)) {
131
+ if (isUseCssSourceMap(disableSourceMap) && output.sourceMap !== true) {
131
132
  var _output4;
132
133
  (_output4 = output).sourceMap || (_output4.sourceMap = {});
133
134
  output.sourceMap.css = true;
@@ -259,7 +260,7 @@ async function parseCommonConfig(uniBuilderConfig, options) {
259
260
  if (!disableTsChecker) {
260
261
  const { pluginTypeCheck } = await Promise.resolve().then(() => __toESM(require("@rsbuild/plugin-type-check")));
261
262
  rsbuildPlugins.push(pluginTypeCheck({
262
- forkTsCheckerOptions: tsChecker
263
+ tsCheckerOptions: tsChecker
263
264
  }));
264
265
  }
265
266
  if (resolveMainFields) {
@@ -2,5 +2,5 @@ import type { RsbuildPlugin, SourceMap } from '@rsbuild/core';
2
2
  import type { DisableSourceMapOption } from '../../types';
3
3
  export declare const pluginDevtool: (options: {
4
4
  disableSourceMap?: DisableSourceMapOption;
5
- sourceMap?: SourceMap;
5
+ sourceMap?: SourceMap | boolean;
6
6
  }) => RsbuildPlugin;
@@ -32,9 +32,10 @@ const pluginDevtool = (options) => ({
32
32
  name: "uni-builder:devtool",
33
33
  setup(api) {
34
34
  var _options_sourceMap;
35
- const devtoolJs = (_options_sourceMap = options.sourceMap) === null || _options_sourceMap === void 0 ? void 0 : _options_sourceMap.js;
35
+ const devtoolJs = typeof options.sourceMap === "boolean" || ((_options_sourceMap = options.sourceMap) === null || _options_sourceMap === void 0 ? void 0 : _options_sourceMap.js) !== void 0;
36
36
  if (devtoolJs) {
37
- if (!isUseJsSourceMap(options.disableSourceMap)) {
37
+ var _options_disableSourceMap;
38
+ if (typeof options.disableSourceMap === "boolean" || ((_options_disableSourceMap = options.disableSourceMap) === null || _options_disableSourceMap === void 0 ? void 0 : _options_disableSourceMap.js) !== void 0) {
38
39
  import_utils.logger.warn("Detected that `output.sourceMap` and `output.disableSourceMap` are used together, use the value of `output.sourceMap`");
39
40
  }
40
41
  return;
package/dist/types.d.ts CHANGED
@@ -97,7 +97,7 @@ export type UniBuilderExtraConfig = {
97
97
  /**
98
98
  * Modify the options of [fork-ts-checker-webpack-plugin](https://github.com/TypeStrong/fork-ts-checker-webpack-plugin).
99
99
  */
100
- tsChecker?: PluginTypeCheckerOptions['forkTsCheckerOptions'];
100
+ tsChecker?: PluginTypeCheckerOptions['tsCheckerOptions'];
101
101
  /**
102
102
  * Modify the options of [css-minimizer-webpack-plugin](https://github.com/webpack-contrib/css-minimizer-webpack-plugin).
103
103
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@modern-js/uni-builder",
3
- "version": "2.62.0",
3
+ "version": "2.63.0",
4
4
  "description": "Unified builder for Modern.js",
5
5
  "repository": {
6
6
  "type": "git",
@@ -26,24 +26,24 @@
26
26
  "@babel/preset-react": "^7.22.15",
27
27
  "@babel/types": "^7.26.0",
28
28
  "@pmmmwh/react-refresh-webpack-plugin": "0.5.15",
29
- "@rsbuild/core": "~1.1.0",
30
- "@rsbuild/plugin-assets-retry": "~1.0.1",
31
- "@rsbuild/plugin-babel": "~1.0.1",
29
+ "@rsbuild/core": "~1.1.5",
30
+ "@rsbuild/plugin-assets-retry": "~1.0.6",
31
+ "@rsbuild/plugin-babel": "~1.0.3",
32
32
  "@rsbuild/plugin-check-syntax": "~1.1.0",
33
33
  "@rsbuild/plugin-css-minimizer": "~1.0.2",
34
34
  "@rsbuild/plugin-less": "~1.1.0",
35
35
  "@rsbuild/plugin-pug": "~1.0.2",
36
- "@rsbuild/plugin-react": "~1.0.3",
37
- "@rsbuild/plugin-rem": "~1.0.1",
38
- "@rsbuild/plugin-sass": "~1.1.0",
36
+ "@rsbuild/plugin-react": "~1.0.7",
37
+ "@rsbuild/plugin-rem": "~1.0.2",
38
+ "@rsbuild/plugin-sass": "~1.1.1",
39
39
  "@rsbuild/plugin-source-build": "~1.0.1",
40
40
  "@rsbuild/plugin-styled-components": "~1.1.0",
41
- "@rsbuild/plugin-svgr": "~1.0.3",
41
+ "@rsbuild/plugin-svgr": "~1.0.5",
42
42
  "@rsbuild/plugin-toml": "~1.0.1",
43
- "@rsbuild/plugin-type-check": "~1.0.1",
43
+ "@rsbuild/plugin-type-check": "~1.1.0",
44
44
  "@rsbuild/plugin-typed-css-modules": "~1.0.2",
45
45
  "@rsbuild/plugin-yaml": "~1.0.2",
46
- "@rsbuild/webpack": "~1.1.0",
46
+ "@rsbuild/webpack": "~1.1.3",
47
47
  "@swc/helpers": "0.5.13",
48
48
  "autoprefixer": "10.4.20",
49
49
  "babel-loader": "9.1.3",
@@ -58,33 +58,33 @@
58
58
  "lodash": "^4.17.21",
59
59
  "picocolors": "^1.0.1",
60
60
  "postcss": "^8.4.35",
61
- "postcss-custom-properties": "13.1.5",
61
+ "postcss-custom-properties": "13.3.12",
62
62
  "postcss-flexbugs-fixes": "5.0.2",
63
63
  "postcss-font-variant": "5.0.0",
64
64
  "postcss-initial": "4.0.1",
65
65
  "postcss-media-minmax": "5.0.0",
66
- "postcss-nesting": "12.0.1",
66
+ "postcss-nesting": "12.1.2",
67
67
  "postcss-page-break": "3.0.4",
68
68
  "react-refresh": "^0.14.0",
69
69
  "rspack-manifest-plugin": "5.0.2",
70
70
  "terser-webpack-plugin": "5.3.10",
71
- "ts-deepmerge": "7.0.1",
71
+ "ts-deepmerge": "7.0.2",
72
72
  "ts-loader": "9.4.4",
73
73
  "webpack": "^5.96.1",
74
74
  "webpack-subresource-integrity": "5.1.0",
75
- "@modern-js/babel-preset": "2.62.0",
76
- "@modern-js/utils": "2.62.0"
75
+ "@modern-js/utils": "2.63.0",
76
+ "@modern-js/babel-preset": "2.63.0"
77
77
  },
78
78
  "devDependencies": {
79
- "@rsbuild/plugin-webpack-swc": "~1.0.3",
79
+ "@rsbuild/plugin-webpack-swc": "~1.0.8",
80
80
  "@types/html-minifier-terser": "^7.0.2",
81
81
  "@types/lodash": "^4.14.202",
82
82
  "react": "^18.3.1",
83
83
  "react-dom": "^18.3.1",
84
84
  "terser": "^5.31.1",
85
85
  "typescript": "^5.3.0",
86
- "@scripts/vitest-config": "2.62.0",
87
- "@scripts/build": "2.62.0"
86
+ "@scripts/vitest-config": "2.63.0",
87
+ "@scripts/build": "2.63.0"
88
88
  },
89
89
  "publishConfig": {
90
90
  "access": "public",