@module-federation/vite 1.0.0-alpha-f2257a4 → 1.0.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.
package/README.md CHANGED
@@ -63,6 +63,12 @@ export default defineConfig({
63
63
  react: {
64
64
  requiredVersion: '18',
65
65
  },
66
+ 'react-dom': {
67
+ requiredVersion: '18',
68
+ },
69
+ 'react-dom/': {
70
+ requiredVersion: '18',
71
+ },
66
72
  },
67
73
  }),
68
74
  // If you set build.target: "chrome89", you can remove this plugin
@@ -6,19 +6,14 @@ interface ExposesItem {
6
6
  export interface NormalizedShared {
7
7
  [key: string]: ShareItem;
8
8
  }
9
- export declare function normalizeRemotes(remotes: Record<string, string | {
10
- type: string;
9
+ export interface RemoteObjectConfig {
10
+ type?: string;
11
11
  name: string;
12
12
  entry: string;
13
- entryGlobalName: string;
14
- shareScope: string;
15
- }> | undefined): Record<string, {
16
- type: string;
17
- name: string;
18
- entry: string;
19
- entryGlobalName: string;
20
- shareScope: string;
21
- }>;
13
+ entryGlobalName?: string;
14
+ shareScope?: string;
15
+ }
16
+ export declare function normalizeRemotes(remotes: Record<string, string | RemoteObjectConfig> | undefined): Record<string, RemoteObjectConfig>;
22
17
  export interface ShareItem {
23
18
  name: string;
24
19
  version: string | undefined;
@@ -38,13 +33,7 @@ export type ModuleFederationOptions = {
38
33
  filename?: string;
39
34
  library?: any;
40
35
  name: string;
41
- remotes?: Record<string, string | {
42
- type: string;
43
- name: string;
44
- entry: string;
45
- entryGlobalName: string;
46
- shareScope: string;
47
- }> | undefined;
36
+ remotes?: Record<string, string | RemoteObjectConfig> | undefined;
48
37
  runtime?: any;
49
38
  shareScope?: string;
50
39
  shared?: string[] | Record<string, string | {
@@ -67,13 +56,7 @@ export interface NormalizedModuleFederationOptions {
67
56
  filename: string;
68
57
  library: any;
69
58
  name: string;
70
- remotes: Record<string, {
71
- type: string;
72
- name: string;
73
- entry: string;
74
- entryGlobalName: string;
75
- shareScope: string;
76
- }>;
59
+ remotes: Record<string, RemoteObjectConfig>;
77
60
  runtime: any;
78
61
  shareScope: string;
79
62
  shared: NormalizedShared;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@module-federation/vite",
3
- "version": "1.0.0-alpha-f2257a4",
3
+ "version": "1.0.0",
4
4
  "description": "Vite plugin for Module Federation",
5
5
  "type": "module",
6
6
  "source": "src/index.ts",
@@ -10,7 +10,6 @@
10
10
  "lib/**/*"
11
11
  ],
12
12
  "scripts": {
13
- "postinstall": "pnpm run build",
14
13
  "prepare": "husky install",
15
14
  "format": "pretty-quick",
16
15
  "dev": "microbundle watch --no-sourcemap --compress=false",