@rsbuild/plugin-stylus 0.7.2 → 0.7.4

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/dist/index.cjs CHANGED
@@ -41,11 +41,11 @@ var pluginStylus = (options) => ({
41
41
  setup(api) {
42
42
  api.modifyBundlerChain(async (chain, { CHAIN_ID }) => {
43
43
  const config = api.getNormalizedConfig();
44
- const mergedOptions = (0, import_shared.mergeChainedOptions)({
45
- defaults: {
44
+ const mergedOptions = (0, import_shared.reduceConfigs)({
45
+ initial: {
46
46
  sourceMap: config.output.sourceMap.css
47
47
  },
48
- options,
48
+ config: options,
49
49
  mergeFn: import_shared.deepmerge
50
50
  });
51
51
  const rule = chain.module.rule(CHAIN_ID.RULE.STYLUS).test(/\.styl(us)?$/).merge({ sideEffects: true }).resolve.preferRelative(true).end();
package/dist/index.js CHANGED
@@ -9,23 +9,23 @@ var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require
9
9
  throw Error('Dynamic require of "' + x + '" is not supported');
10
10
  });
11
11
 
12
- // ../../node_modules/.pnpm/@modern-js+module-tools@2.50.0_eslint@9.4.0_typescript@5.4.5/node_modules/@modern-js/module-tools/shims/esm.js
12
+ // ../../node_modules/.pnpm/@modern-js+module-tools@2.52.0_eslint@9.4.0_typescript@5.4.5/node_modules/@modern-js/module-tools/shims/esm.js
13
13
  import { fileURLToPath } from "url";
14
14
  import path from "path";
15
15
 
16
16
  // src/index.ts
17
- import { cloneDeep, deepmerge, mergeChainedOptions } from "@rsbuild/shared";
17
+ import { cloneDeep, deepmerge, reduceConfigs } from "@rsbuild/shared";
18
18
  var PLUGIN_STYLUS_NAME = "rsbuild:stylus";
19
19
  var pluginStylus = (options) => ({
20
20
  name: PLUGIN_STYLUS_NAME,
21
21
  setup(api) {
22
22
  api.modifyBundlerChain(async (chain, { CHAIN_ID }) => {
23
23
  const config = api.getNormalizedConfig();
24
- const mergedOptions = mergeChainedOptions({
25
- defaults: {
24
+ const mergedOptions = reduceConfigs({
25
+ initial: {
26
26
  sourceMap: config.output.sourceMap.css
27
27
  },
28
- options,
28
+ config: options,
29
29
  mergeFn: deepmerge
30
30
  });
31
31
  const rule = chain.module.rule(CHAIN_ID.RULE.STYLUS).test(/\.styl(us)?$/).merge({ sideEffects: true }).resolve.preferRelative(true).end();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rsbuild/plugin-stylus",
3
- "version": "0.7.2",
3
+ "version": "0.7.4",
4
4
  "description": "Stylus plugin for Rsbuild",
5
5
  "homepage": "https://rsbuild.dev",
6
6
  "repository": {
@@ -25,15 +25,15 @@
25
25
  "dependencies": {
26
26
  "stylus": "0.63.0",
27
27
  "stylus-loader": "8.1.0",
28
- "@rsbuild/shared": "0.7.2"
28
+ "@rsbuild/shared": "0.7.4"
29
29
  },
30
30
  "devDependencies": {
31
31
  "typescript": "^5.4.2",
32
- "@rsbuild/core": "0.7.2",
33
- "@scripts/test-helper": "0.7.2"
32
+ "@rsbuild/core": "0.7.4",
33
+ "@scripts/test-helper": "0.7.4"
34
34
  },
35
35
  "peerDependencies": {
36
- "@rsbuild/core": "^0.7.2"
36
+ "@rsbuild/core": "^0.7.4"
37
37
  },
38
38
  "publishConfig": {
39
39
  "access": "public",