@lemon-fe/vite-plugin-micro-frontend 1.1.1 → 1.1.2

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.d.ts CHANGED
@@ -1,4 +1,6 @@
1
1
  import { Plugin, PluginOption } from 'vite';
2
+ export { default as cssInjectedByJsPlugin } from 'vite-plugin-css-injected-by-js';
3
+ import { VitePluginFederationOptions } from '@originjs/vite-plugin-federation';
2
4
  import { ComponentType } from 'react';
3
5
 
4
6
  /**
@@ -11,20 +13,17 @@ interface RemoteConfig {
11
13
  remoteName: string;
12
14
  /** 入口文件路径 */
13
15
  entry: string;
16
+ /** 是否为 ES Module */
17
+ isESModule?: boolean;
14
18
  }
15
19
  /**
16
20
  * 模块联邦配置
17
21
  */
18
- interface FederationConfig {
22
+ interface FederationConfig extends Omit<VitePluginFederationOptions, "remotes"> {
19
23
  /** 应用名称 */
20
24
  name: string;
21
25
  /** 远程入口文件名 */
22
26
  filename?: string;
23
- /**
24
- * 暴露的模块(手动配置)
25
- * 会与自动扫描的 exposes 合并,手动配置优先级更高
26
- */
27
- exposes?: Record<string, string>;
28
27
  /**
29
28
  * exposes 目录路径,默认为 src/exposes
30
29
  * 插件会自动扫描该目录下的子目录作为暴露的模块
@@ -33,8 +32,6 @@ interface FederationConfig {
33
32
  exposesDir?: string;
34
33
  /** 远程模块配置 */
35
34
  remotes?: RemoteConfig[];
36
- /** 共享依赖 */
37
- shared?: string[];
38
35
  /** 生成的文件路径,默认为 src/utils/mf.tsx */
39
36
  outputPath?: string;
40
37
  /**