Skip to content

Commit 9716aa6

Browse files
committed
chore: sync code
2 parents 08ddd5f + b821370 commit 9716aa6

File tree

59 files changed

+1599
-548
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+1599
-548
lines changed

examples/module-federation/mf-host/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@
1212
"react-dom": "^18.3.1"
1313
},
1414
"devDependencies": {
15-
"@module-federation/rsbuild-plugin": "^0.6.15",
16-
"@rsbuild/core": "~1.0.19",
17-
"@rsbuild/plugin-react": "^1.0.6",
15+
"@module-federation/rsbuild-plugin": "^0.7.1",
16+
"@rsbuild/core": "~1.1.0",
17+
"@rsbuild/plugin-react": "^1.0.7",
1818
"@types/react": "^18.3.12",
1919
"@types/react-dom": "^18.3.1",
2020
"typescript": "^5.6.3"

examples/module-federation/mf-react-component/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@
1818
"storybook": "storybook dev -p 6006"
1919
},
2020
"devDependencies": {
21-
"@module-federation/enhanced": "^0.6.15",
22-
"@module-federation/rsbuild-plugin": "^0.6.15",
21+
"@module-federation/enhanced": "^0.7.1",
22+
"@module-federation/rsbuild-plugin": "^0.7.1",
2323
"@module-federation/storybook-addon": "0.0.0-next-20241106024856",
24-
"@rsbuild/plugin-react": "^1.0.6",
24+
"@rsbuild/plugin-react": "^1.0.7",
2525
"@rslib/core": "workspace:*",
2626
"@types/react": "^18.3.12",
2727
"http-server": "^14.1.1",

examples/module-federation/mf-react-component/stories/index.stories.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import React from 'react';
12
// @ts-ignore ignore remote module type check for passing ci run build because we set @mf-types folder in .gitignore
23
import { Counter } from 'rslib-module';
34

examples/module-federation/mf-remote/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@
1212
"react-dom": "^18.3.1"
1313
},
1414
"devDependencies": {
15-
"@module-federation/rsbuild-plugin": "^0.6.15",
16-
"@rsbuild/core": "~1.0.19",
17-
"@rsbuild/plugin-react": "^1.0.6",
15+
"@module-federation/rsbuild-plugin": "^0.7.1",
16+
"@rsbuild/core": "~1.1.0",
17+
"@rsbuild/plugin-react": "^1.0.7",
1818
"@types/react": "^18.3.12",
1919
"@types/react-dom": "^18.3.1",
2020
"typescript": "^5.6.3"

examples/react-component-bundle-false/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"build": "rslib build"
99
},
1010
"devDependencies": {
11-
"@rsbuild/plugin-react": "^1.0.6",
11+
"@rsbuild/plugin-react": "^1.0.7",
1212
"@rsbuild/plugin-sass": "^1.1.0",
1313
"@rslib/core": "workspace:*",
1414
"@types/react": "^18.3.12",

examples/react-component-bundle/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"build": "rslib build"
99
},
1010
"devDependencies": {
11-
"@rsbuild/plugin-react": "^1.0.6",
11+
"@rsbuild/plugin-react": "^1.0.7",
1212
"@rsbuild/plugin-sass": "^1.1.0",
1313
"@rslib/core": "workspace:*",
1414
"@types/react": "^18.3.12",

examples/react-component-umd/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"build": "rslib build"
88
},
99
"devDependencies": {
10-
"@rsbuild/plugin-react": "^1.0.6",
10+
"@rsbuild/plugin-react": "^1.0.7",
1111
"@rsbuild/plugin-sass": "^1.1.0",
1212
"@rslib/core": "workspace:*",
1313
"@types/react": "^18.3.12",

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,13 +49,13 @@
4949
"cspell-ban-words": "^0.0.4",
5050
"fs-extra": "^11.2.0",
5151
"nano-staged": "^0.8.0",
52-
"nx": "^20.0.8",
52+
"nx": "^20.0.12",
5353
"prettier": "^3.3.3",
5454
"prettier-plugin-packagejson": "^2.5.3",
5555
"simple-git-hooks": "^2.11.1",
5656
"typescript": "^5.6.3",
5757
"vitest": "^2.1.4",
58-
"zx": "^8.2.0"
58+
"zx": "^8.2.1"
5959
},
6060
"packageManager": "[email protected]",
6161
"engines": {

packages/core/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
"prebundle": "prebundle"
3838
},
3939
"dependencies": {
40-
"@rsbuild/core": "~1.0.19",
40+
"@rsbuild/core": "~1.1.0",
4141
"rsbuild-plugin-dts": "workspace:*",
4242
"tinyglobby": "^0.2.10"
4343
},
@@ -50,7 +50,7 @@
5050
"memfs": "^4.14.0",
5151
"picocolors": "1.1.1",
5252
"prebundle": "1.2.5",
53-
"rslib": "npm:@rslib/[email protected].15",
53+
"rslib": "npm:@rslib/[email protected].16",
5454
"rslog": "^1.2.3",
5555
"tsconfck": "3.1.4",
5656
"typescript": "^5.6.3"

packages/core/src/build.ts

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,18 @@
1-
import type { RsbuildInstance } from '@rsbuild/core';
1+
import { type RsbuildInstance, createRsbuild } from '@rsbuild/core';
22
import type { BuildOptions } from './cli/commands';
3-
import { initRsbuild } from './config';
3+
import { composeRsbuildEnvironments, pruneEnvironments } from './config';
44
import type { RslibConfig } from './types/config';
55

66
export async function build(
77
config: RslibConfig,
88
options?: BuildOptions,
99
): Promise<RsbuildInstance> {
10-
const rsbuildInstance = await initRsbuild(config);
10+
const environments = await composeRsbuildEnvironments(config);
11+
const rsbuildInstance = await createRsbuild({
12+
rsbuildConfig: {
13+
environments: pruneEnvironments(environments, options?.lib),
14+
},
15+
});
1116

1217
await rsbuildInstance.build({
1318
watch: options?.watch,

0 commit comments

Comments
 (0)