web-extend-plugin-vue2 0.3.4 → 0.3.6
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 +40 -1
- package/dist/index.cjs +116 -20
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +115 -21
- package/dist/index.mjs.map +1 -1
- package/index.d.ts +21 -0
- package/package.json +6 -2
package/index.d.ts
CHANGED
|
@@ -61,6 +61,13 @@ export type HostModuleRegistry =
|
|
|
61
61
|
| Record<string, unknown | HostModuleEntry>
|
|
62
62
|
| Array<(HostModuleEntry & { name: string })>
|
|
63
63
|
|
|
64
|
+
export type RegisterVueGlobalComponentsOptions = {
|
|
65
|
+
source?: Record<string, unknown>
|
|
66
|
+
include?: (name: string, component: unknown) => boolean
|
|
67
|
+
mapName?: (name: string, component: unknown) => string | null | undefined
|
|
68
|
+
meta?: HostComponentMeta | ((name: string, component: unknown) => HostComponentMeta | undefined)
|
|
69
|
+
}
|
|
70
|
+
|
|
64
71
|
export type HostUiCapability = {
|
|
65
72
|
framework?: string
|
|
66
73
|
componentLibrary?: string
|
|
@@ -80,6 +87,11 @@ export type HostContext = Readonly<
|
|
|
80
87
|
}
|
|
81
88
|
>
|
|
82
89
|
|
|
90
|
+
export type HostBridgeOptions = {
|
|
91
|
+
modules?: Record<string, unknown>
|
|
92
|
+
components?: Record<string, unknown | { component: unknown }>
|
|
93
|
+
}
|
|
94
|
+
|
|
83
95
|
export type OnBeforePluginActivateFn = (ctx: {
|
|
84
96
|
pluginId: string
|
|
85
97
|
router: unknown
|
|
@@ -242,6 +254,10 @@ export function disposeWebPlugin(pluginId: string): void
|
|
|
242
254
|
export const registries: unknown
|
|
243
255
|
export function registerHostModules(input: HostModuleRegistry): Readonly<Record<string, HostModuleMeta>>
|
|
244
256
|
export function registerHostComponents(input: HostComponentRegistry): Readonly<Record<string, HostComponentMeta>>
|
|
257
|
+
export function registerVueGlobalComponents(
|
|
258
|
+
VueRuntime: unknown,
|
|
259
|
+
options?: RegisterVueGlobalComponentsOptions
|
|
260
|
+
): Readonly<Record<string, HostComponentMeta>>
|
|
245
261
|
export function getHostModule(name: string): unknown
|
|
246
262
|
export function getHostModuleMeta(name: string): HostModuleMeta | undefined
|
|
247
263
|
export function getAllHostModuleMeta(): Readonly<Record<string, HostModuleMeta>>
|
|
@@ -263,6 +279,11 @@ export function installWebExtendPluginVue2(
|
|
|
263
279
|
options?: WebExtendPluginRuntimeOptions
|
|
264
280
|
): Promise<void>
|
|
265
281
|
|
|
282
|
+
export function installHostBridge(
|
|
283
|
+
Vue: unknown,
|
|
284
|
+
options?: HostBridgeOptions
|
|
285
|
+
): Readonly<Record<string, unknown>>
|
|
286
|
+
|
|
266
287
|
export const ExtensionPoint: unknown
|
|
267
288
|
|
|
268
289
|
export function createVueCliAxiosInstallOptions(
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "web-extend-plugin-vue2",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.6",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -45,9 +45,13 @@
|
|
|
45
45
|
"license": "Apache-2.0",
|
|
46
46
|
"repository": {
|
|
47
47
|
"type": "git",
|
|
48
|
-
"url": "",
|
|
48
|
+
"url": "https://github.com/xtemplus/extend-plugin-framework.git",
|
|
49
49
|
"directory": "web-extend-plugin-vue2"
|
|
50
50
|
},
|
|
51
|
+
"bugs": {
|
|
52
|
+
"url": "https://github.com/xtemplus/extend-plugin-framework/issues"
|
|
53
|
+
},
|
|
54
|
+
"homepage": "https://github.com/xtemplus/extend-plugin-framework/tree/master/web-extend-plugin-vue2#readme",
|
|
51
55
|
"keywords": [
|
|
52
56
|
"vue2",
|
|
53
57
|
"plugin",
|