@modern-js/plugin 1.18.1-beta.1 → 1.18.1

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/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @modern-js/plugin
2
2
 
3
+ ## 1.18.1
4
+
5
+ ### Patch Changes
6
+
7
+ - c1a4d9b: fix(plugin): incorrect createManager type in TS 4.8
8
+
9
+ fix(plugin): 修复 createManager 在 TS 4.8 下的类型问题
10
+
3
11
  ## 1.18.0
4
12
 
5
13
  ## 1.17.0
@@ -68,7 +68,7 @@ export declare const DEFAULT_OPTIONS: {
68
68
  usePlugins: never[];
69
69
  registerHook: {};
70
70
  };
71
- export declare const createManager: <Hooks, API extends Record<string, any> = Record<string, never>>(hooks?: Partial<Hooks> | undefined, api?: API | undefined) => Manager<Hooks, API>;
71
+ export declare const createManager: <Hooks extends Record<string, any>, API extends Record<string, any> = Record<string, never>>(hooks?: Partial<Hooks> | undefined, api?: API | undefined) => Manager<Hooks, API>;
72
72
  export declare const generateRunner: <Hooks extends Record<string, any>>(hooksList: (void | Partial<ToThreads<Hooks>>)[], hooksMap?: Hooks | undefined) => ToRunners<Hooks>;
73
73
  export declare const cloneHook: (hook: Hook) => Hook;
74
74
  export declare const cloneHooksMap: <Hooks>(record: Hooks) => Hooks;
package/package.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "modern",
12
12
  "modern.js"
13
13
  ],
14
- "version": "1.18.1-beta.1",
14
+ "version": "1.18.1",
15
15
  "jsnext:source": "./src/index.ts",
16
16
  "types": "./dist/types/index.d.ts",
17
17
  "main": "./dist/js/node/index.js",
@@ -24,7 +24,6 @@
24
24
  "import": "./dist/js/modern/index.js",
25
25
  "require": "./dist/js/node/index.js"
26
26
  },
27
- "types": "./dist/types/index.d.ts",
28
27
  "default": "./dist/js/treeshaking/index.js"
29
28
  }
30
29
  },
@@ -35,15 +34,14 @@
35
34
  "@types/jest": "^27",
36
35
  "@types/node": "^14",
37
36
  "typescript": "^4",
38
- "@scripts/build": "1.18.0",
37
+ "@scripts/build": "1.18.1",
39
38
  "jest": "^27",
40
- "@scripts/jest-config": "1.18.0"
39
+ "@scripts/jest-config": "1.18.1"
41
40
  },
42
41
  "sideEffects": false,
43
42
  "publishConfig": {
44
43
  "registry": "https://registry.npmjs.org/",
45
- "access": "public",
46
- "types": "./dist/types/index.d.ts"
44
+ "access": "public"
47
45
  },
48
46
  "wireit": {
49
47
  "build": {