@dcloudio/uni-cli-shared 3.0.0-alpha-4070720250804001 → 3.0.0-alpha-4070620250731002
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/easycom.d.ts +0 -1
- package/dist/easycom.js +13 -17
- package/dist/hbx/alias.js +10 -43
- package/dist/hbx/index.js +0 -10
- package/dist/hbx/log.js +1 -23
- package/dist/index.d.ts +1 -2
- package/dist/index.js +1 -3
- package/dist/json/index.d.ts +1 -1
- package/dist/json/index.js +1 -2
- package/dist/json/manifest.d.ts +0 -1
- package/dist/json/manifest.js +1 -11
- package/dist/json/mp/jsonFile.js +2 -4
- package/dist/json/mp/pages.js +0 -1
- package/dist/json/mp/types.d.ts +1 -4
- package/dist/json/uni-x/manifest.d.ts +0 -1
- package/dist/json/uni-x/manifest.js +1 -5
- package/dist/messages/zh_CN.js +0 -1
- package/dist/uni_modules.cloud.d.ts +4 -10
- package/dist/uni_modules.cloud.js +19 -58
- package/dist/uni_modules.d.ts +0 -2
- package/dist/uni_modules.js +2 -81
- package/dist/uts.js +0 -16
- package/dist/vite/autoImport.js +0 -2
- package/dist/vite/cloud.js +5 -51
- package/dist/vite/plugins/index.d.ts +0 -1
- package/dist/vite/plugins/index.js +1 -3
- package/dist/vite/plugins/inject.js +1 -3
- package/dist/vite/plugins/uts/uni_modules.d.ts +0 -1
- package/dist/vite/plugins/uts/uni_modules.js +14 -63
- package/dist/vite/plugins/uts/uvue.js +3 -17
- package/dist/vite/plugins/vitejs/plugins/css.js +5 -40
- package/dist/vue/transforms/transformUTSComponent.js +3 -8
- package/package.json +38 -38
- package/dist/vite/plugins/stats.d.ts +0 -2
- package/dist/vite/plugins/stats.js +0 -42
- package/dist/workers.d.ts +0 -14
- package/dist/workers.js +0 -187
- package/lib/vapor/@vitejs/plugin-vue/LICENSE +0 -21
- package/lib/vapor/@vitejs/plugin-vue/README.md +0 -278
- package/lib/vapor/@vitejs/plugin-vue/dist/index.cjs +0 -3105
- package/lib/vapor/@vitejs/plugin-vue/dist/index.d.cts +0 -113
- package/lib/vapor/@vitejs/plugin-vue/dist/index.d.mts +0 -111
- package/lib/vapor/@vitejs/plugin-vue/dist/index.d.ts +0 -113
- package/lib/vapor/@vitejs/plugin-vue/dist/index.mjs +0 -3090
- package/lib/vapor/@vitejs/plugin-vue/package.json +0 -50
- package/lib/vapor/@vue/compiler-core/LICENSE +0 -21
- package/lib/vapor/@vue/compiler-core/README.md +0 -1
- package/lib/vapor/@vue/compiler-core/dist/compiler-core.cjs.js +0 -6902
- package/lib/vapor/@vue/compiler-core/dist/compiler-core.cjs.prod.js +0 -6779
- package/lib/vapor/@vue/compiler-core/dist/compiler-core.esm-bundler.js +0 -5870
- package/lib/vapor/@vue/compiler-core/index.js +0 -7
- package/lib/vapor/@vue/compiler-core/package.json +0 -58
- package/lib/vapor/@vue/compiler-dom/LICENSE +0 -21
- package/lib/vapor/@vue/compiler-dom/README.md +0 -1
- package/lib/vapor/@vue/compiler-dom/dist/compiler-dom.cjs.js +0 -936
- package/lib/vapor/@vue/compiler-dom/dist/compiler-dom.cjs.prod.js +0 -856
- package/lib/vapor/@vue/compiler-dom/dist/compiler-dom.esm-browser.js +0 -6682
- package/lib/vapor/@vue/compiler-dom/dist/compiler-dom.esm-browser.prod.js +0 -14
- package/lib/vapor/@vue/compiler-dom/dist/compiler-dom.esm-bundler.js +0 -693
- package/lib/vapor/@vue/compiler-dom/dist/compiler-dom.global.js +0 -6855
- package/lib/vapor/@vue/compiler-dom/dist/compiler-dom.global.prod.js +0 -14
- package/lib/vapor/@vue/compiler-dom/index.js +0 -7
- package/lib/vapor/@vue/compiler-dom/package.json +0 -57
- package/lib/vapor/@vue/compiler-sfc/LICENSE +0 -21
- package/lib/vapor/@vue/compiler-sfc/README.md +0 -80
- package/lib/vapor/@vue/compiler-sfc/dist/compiler-sfc.cjs.js +0 -21682
- package/lib/vapor/@vue/compiler-sfc/dist/compiler-sfc.esm-browser.js +0 -66272
- package/lib/vapor/@vue/compiler-sfc/package.json +0 -68
- package/lib/vapor/@vue/compiler-ssr/LICENSE +0 -21
- package/lib/vapor/@vue/compiler-ssr/README.md +0 -1
- package/lib/vapor/@vue/compiler-ssr/dist/compiler-ssr.cjs.js +0 -1402
- package/lib/vapor/@vue/compiler-ssr/package.json +0 -34
- package/lib/vapor/@vue/compiler-vapor/LICENSE +0 -21
- package/lib/vapor/@vue/compiler-vapor/README.md +0 -1
- package/lib/vapor/@vue/compiler-vapor/dist/compiler-vapor.cjs.js +0 -4540
- package/lib/vapor/@vue/compiler-vapor/dist/compiler-vapor.esm-browser.js +0 -37020
- package/lib/vapor/@vue/compiler-vapor/package.json +0 -49
- package/lib/vapor/@vue/reactivity/LICENSE +0 -21
- package/lib/vapor/@vue/reactivity/README.md +0 -19
- package/lib/vapor/@vue/reactivity/dist/reactivity.cjs.js +0 -2033
- package/lib/vapor/@vue/reactivity/dist/reactivity.cjs.prod.js +0 -1841
- package/lib/vapor/@vue/reactivity/dist/reactivity.esm-browser.js +0 -2023
- package/lib/vapor/@vue/reactivity/dist/reactivity.esm-browser.prod.js +0 -5
- package/lib/vapor/@vue/reactivity/dist/reactivity.esm-bundler.js +0 -1992
- package/lib/vapor/@vue/reactivity/dist/reactivity.global.js +0 -2082
- package/lib/vapor/@vue/reactivity/dist/reactivity.global.prod.js +0 -5
- package/lib/vapor/@vue/reactivity/index.js +0 -7
- package/lib/vapor/@vue/reactivity/package.json +0 -55
- package/lib/vapor/@vue/runtime-core/LICENSE +0 -21
- package/lib/vapor/@vue/runtime-core/README.md +0 -28
- package/lib/vapor/@vue/runtime-core/dist/runtime-core.cjs.js +0 -8972
- package/lib/vapor/@vue/runtime-core/dist/runtime-core.cjs.prod.js +0 -7088
- package/lib/vapor/@vue/runtime-core/dist/runtime-core.esm-bundler.js +0 -8913
- package/lib/vapor/@vue/runtime-core/index.js +0 -7
- package/lib/vapor/@vue/runtime-core/package.json +0 -54
- package/lib/vapor/@vue/runtime-dom/LICENSE +0 -21
- package/lib/vapor/@vue/runtime-dom/README.md +0 -13
- package/lib/vapor/@vue/runtime-dom/dist/runtime-dom.cjs.js +0 -1797
- package/lib/vapor/@vue/runtime-dom/dist/runtime-dom.cjs.prod.js +0 -1646
- package/lib/vapor/@vue/runtime-dom/dist/runtime-dom.esm-browser.js +0 -12929
- package/lib/vapor/@vue/runtime-dom/dist/runtime-dom.esm-browser.prod.js +0 -6
- package/lib/vapor/@vue/runtime-dom/dist/runtime-dom.esm-bundler.js +0 -1838
- package/lib/vapor/@vue/runtime-dom/dist/runtime-dom.global.js +0 -13086
- package/lib/vapor/@vue/runtime-dom/dist/runtime-dom.global.prod.js +0 -6
- package/lib/vapor/@vue/runtime-dom/index.js +0 -7
- package/lib/vapor/@vue/runtime-dom/package.json +0 -60
- package/lib/vapor/@vue/runtime-vapor/LICENSE +0 -21
- package/lib/vapor/@vue/runtime-vapor/README.md +0 -8
- package/lib/vapor/@vue/runtime-vapor/dist/runtime-vapor.esm-bundler.js +0 -3242
- package/lib/vapor/@vue/runtime-vapor/package.json +0 -47
- package/lib/vapor/@vue/server-renderer/LICENSE +0 -21
- package/lib/vapor/@vue/server-renderer/README.md +0 -178
- package/lib/vapor/@vue/server-renderer/dist/server-renderer.cjs.js +0 -1144
- package/lib/vapor/@vue/server-renderer/dist/server-renderer.cjs.prod.js +0 -871
- package/lib/vapor/@vue/server-renderer/dist/server-renderer.esm-browser.js +0 -8756
- package/lib/vapor/@vue/server-renderer/dist/server-renderer.esm-browser.prod.js +0 -5
- package/lib/vapor/@vue/server-renderer/dist/server-renderer.esm-bundler.js +0 -1366
- package/lib/vapor/@vue/server-renderer/index.js +0 -7
- package/lib/vapor/@vue/server-renderer/package.json +0 -55
- package/lib/vapor/@vue/shared/LICENSE +0 -21
- package/lib/vapor/@vue/shared/README.md +0 -3
- package/lib/vapor/@vue/shared/dist/shared.cjs.js +0 -698
- package/lib/vapor/@vue/shared/dist/shared.cjs.prod.js +0 -690
- package/lib/vapor/@vue/shared/dist/shared.esm-bundler.js +0 -616
- package/lib/vapor/@vue/shared/index.js +0 -7
- package/lib/vapor/@vue/shared/package.json +0 -47
- package/lib/vapor/@vue/vue/LICENSE +0 -21
- package/lib/vapor/@vue/vue/README.md +0 -62
- package/lib/vapor/@vue/vue/compiler-sfc/index.browser.js +0 -1
- package/lib/vapor/@vue/vue/compiler-sfc/index.browser.mjs +0 -1
- package/lib/vapor/@vue/vue/compiler-sfc/index.d.mts +0 -1
- package/lib/vapor/@vue/vue/compiler-sfc/index.d.ts +0 -1
- package/lib/vapor/@vue/vue/compiler-sfc/index.js +0 -3
- package/lib/vapor/@vue/vue/compiler-sfc/index.mjs +0 -3
- package/lib/vapor/@vue/vue/compiler-sfc/package.json +0 -4
- package/lib/vapor/@vue/vue/compiler-sfc/register-ts.js +0 -3
- package/lib/vapor/@vue/vue/dist/vue.cjs.js +0 -80
- package/lib/vapor/@vue/vue/dist/vue.cjs.prod.js +0 -66
- package/lib/vapor/@vue/vue/dist/vue.esm-browser.js +0 -18840
- package/lib/vapor/@vue/vue/dist/vue.esm-browser.prod.js +0 -12
- package/lib/vapor/@vue/vue/dist/vue.esm-bundler.js +0 -72
- package/lib/vapor/@vue/vue/dist/vue.global.js +0 -18820
- package/lib/vapor/@vue/vue/dist/vue.global.prod.js +0 -12
- package/lib/vapor/@vue/vue/dist/vue.runtime-with-vapor.esm-browser.js +0 -15648
- package/lib/vapor/@vue/vue/dist/vue.runtime-with-vapor.esm-browser.prod.js +0 -9
- package/lib/vapor/@vue/vue/dist/vue.runtime.esm-browser.js +0 -12953
- package/lib/vapor/@vue/vue/dist/vue.runtime.esm-browser.prod.js +0 -6
- package/lib/vapor/@vue/vue/dist/vue.runtime.esm-bundler.js +0 -29
- package/lib/vapor/@vue/vue/dist/vue.runtime.global.js +0 -13111
- package/lib/vapor/@vue/vue/dist/vue.runtime.global.prod.js +0 -6
- package/lib/vapor/@vue/vue/index.js +0 -7
- package/lib/vapor/@vue/vue/index.mjs +0 -1
- package/lib/vapor/@vue/vue/jsx-runtime/index.d.ts +0 -25
- package/lib/vapor/@vue/vue/jsx-runtime/index.js +0 -15
- package/lib/vapor/@vue/vue/jsx-runtime/index.mjs +0 -12
- package/lib/vapor/@vue/vue/jsx-runtime/package.json +0 -5
- package/lib/vapor/@vue/vue/jsx.d.ts +0 -22
- package/lib/vapor/@vue/vue/package.json +0 -114
- package/lib/vapor/@vue/vue/server-renderer/index.d.mts +0 -1
- package/lib/vapor/@vue/vue/server-renderer/index.d.ts +0 -1
- package/lib/vapor/@vue/vue/server-renderer/index.js +0 -1
- package/lib/vapor/@vue/vue/server-renderer/index.mjs +0 -1
- package/lib/vapor/@vue/vue/server-renderer/package.json +0 -4
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
import { Plugin, ViteDevServer } from 'vite';
|
|
2
|
-
import * as _compiler from 'vue/compiler-sfc';
|
|
3
|
-
import { SFCScriptCompileOptions, SFCTemplateCompileOptions, SFCStyleCompileOptions } from 'vue/compiler-sfc';
|
|
4
|
-
|
|
5
|
-
interface VueQuery {
|
|
6
|
-
vue?: boolean;
|
|
7
|
-
src?: string;
|
|
8
|
-
type?: 'script' | 'template' | 'style' | 'custom';
|
|
9
|
-
index?: number;
|
|
10
|
-
lang?: string;
|
|
11
|
-
raw?: boolean;
|
|
12
|
-
url?: boolean;
|
|
13
|
-
scoped?: boolean;
|
|
14
|
-
id?: string;
|
|
15
|
-
}
|
|
16
|
-
declare function parseVueRequest(id: string): {
|
|
17
|
-
filename: string;
|
|
18
|
-
query: VueQuery;
|
|
19
|
-
};
|
|
20
|
-
|
|
21
|
-
interface Options {
|
|
22
|
-
include?: string | RegExp | (string | RegExp)[];
|
|
23
|
-
exclude?: string | RegExp | (string | RegExp)[];
|
|
24
|
-
/**
|
|
25
|
-
* In Vite, this option follows Vite's config.
|
|
26
|
-
*/
|
|
27
|
-
isProduction?: boolean;
|
|
28
|
-
script?: Partial<Omit<SFCScriptCompileOptions, 'id' | 'isProd' | 'inlineTemplate' | 'templateOptions' | 'sourceMap' | 'genDefaultAs' | 'customElement' | 'defineModel' | 'propsDestructure'>> & {
|
|
29
|
-
/**
|
|
30
|
-
* @deprecated defineModel is now a stable feature and always enabled if
|
|
31
|
-
* using Vue 3.4 or above.
|
|
32
|
-
*/
|
|
33
|
-
defineModel?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* @deprecated moved to `features.propsDestructure`.
|
|
36
|
-
*/
|
|
37
|
-
propsDestructure?: boolean;
|
|
38
|
-
};
|
|
39
|
-
template?: Partial<Omit<SFCTemplateCompileOptions, 'id' | 'source' | 'ast' | 'filename' | 'scoped' | 'slotted' | 'isProd' | 'inMap' | 'ssr' | 'ssrCssVars' | 'preprocessLang'>>;
|
|
40
|
-
style?: Partial<Omit<SFCStyleCompileOptions, 'filename' | 'id' | 'isProd' | 'source' | 'scoped' | 'cssDevSourcemap' | 'postcssOptions' | 'map' | 'postcssPlugins' | 'preprocessCustomRequire' | 'preprocessLang' | 'preprocessOptions'>>;
|
|
41
|
-
/**
|
|
42
|
-
* Use custom compiler-sfc instance. Can be used to force a specific version.
|
|
43
|
-
*/
|
|
44
|
-
compiler?: typeof _compiler;
|
|
45
|
-
/**
|
|
46
|
-
* Requires @vitejs/plugin-vue@^5.1.0
|
|
47
|
-
*/
|
|
48
|
-
features?: {
|
|
49
|
-
/**
|
|
50
|
-
* Enable reactive destructure for `defineProps`.
|
|
51
|
-
* - Available in Vue 3.4 and later.
|
|
52
|
-
* - **default:** `false` in Vue 3.4 (**experimental**), `true` in Vue 3.5+
|
|
53
|
-
*/
|
|
54
|
-
propsDestructure?: boolean;
|
|
55
|
-
/**
|
|
56
|
-
* Transform Vue SFCs into custom elements.
|
|
57
|
-
* - `true`: all `*.vue` imports are converted into custom elements
|
|
58
|
-
* - `string | RegExp`: matched files are converted into custom elements
|
|
59
|
-
* - **default:** /\.ce\.vue$/
|
|
60
|
-
*/
|
|
61
|
-
customElement?: boolean | string | RegExp | (string | RegExp)[];
|
|
62
|
-
/**
|
|
63
|
-
* Set to `false` to disable Options API support and allow related code in
|
|
64
|
-
* Vue core to be dropped via dead-code elimination in production builds,
|
|
65
|
-
* resulting in smaller bundles.
|
|
66
|
-
* - **default:** `true`
|
|
67
|
-
*/
|
|
68
|
-
optionsAPI?: boolean;
|
|
69
|
-
/**
|
|
70
|
-
* Set to `true` to enable devtools support in production builds.
|
|
71
|
-
* Results in slightly larger bundles.
|
|
72
|
-
* - **default:** `false`
|
|
73
|
-
*/
|
|
74
|
-
prodDevtools?: boolean;
|
|
75
|
-
/**
|
|
76
|
-
* Set to `true` to enable detailed information for hydration mismatch
|
|
77
|
-
* errors in production builds. Results in slightly larger bundles.
|
|
78
|
-
* - **default:** `false`
|
|
79
|
-
*/
|
|
80
|
-
prodHydrationMismatchDetails?: boolean;
|
|
81
|
-
/**
|
|
82
|
-
* Customize the component ID generation strategy.
|
|
83
|
-
* - `'filepath'`: hash the file path (relative to the project root)
|
|
84
|
-
* - `'filepath-source'`: hash the file path and the source code
|
|
85
|
-
* - `function`: custom function that takes the file path, source code,
|
|
86
|
-
* whether in production mode, and the default hash function as arguments
|
|
87
|
-
* - **default:** `'filepath'` in development, `'filepath-source'` in production
|
|
88
|
-
*/
|
|
89
|
-
componentIdGenerator?: 'filepath' | 'filepath-source' | ((filepath: string, source: string, isProduction: boolean | undefined, getHash: (text: string) => string) => string);
|
|
90
|
-
};
|
|
91
|
-
/**
|
|
92
|
-
* @deprecated moved to `features.customElement`.
|
|
93
|
-
*/
|
|
94
|
-
customElement?: boolean | string | RegExp | (string | RegExp)[];
|
|
95
|
-
}
|
|
96
|
-
interface ResolvedOptions extends Options {
|
|
97
|
-
compiler: typeof _compiler;
|
|
98
|
-
root: string;
|
|
99
|
-
sourceMap: boolean;
|
|
100
|
-
cssDevSourcemap: boolean;
|
|
101
|
-
devServer?: ViteDevServer;
|
|
102
|
-
devToolsEnabled?: boolean;
|
|
103
|
-
}
|
|
104
|
-
interface Api {
|
|
105
|
-
get options(): ResolvedOptions;
|
|
106
|
-
set options(value: ResolvedOptions);
|
|
107
|
-
version: string;
|
|
108
|
-
}
|
|
109
|
-
declare function vuePlugin(rawOptions?: Options): Plugin<Api>;
|
|
110
|
-
|
|
111
|
-
// @ts-ignore
|
|
112
|
-
export = vuePlugin;
|
|
113
|
-
export { type Api, type Options, type ResolvedOptions, type VueQuery, parseVueRequest };
|
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
import { Plugin, ViteDevServer } from 'vite';
|
|
2
|
-
import * as _compiler from 'vue/compiler-sfc';
|
|
3
|
-
import { SFCScriptCompileOptions, SFCTemplateCompileOptions, SFCStyleCompileOptions } from 'vue/compiler-sfc';
|
|
4
|
-
|
|
5
|
-
interface VueQuery {
|
|
6
|
-
vue?: boolean;
|
|
7
|
-
src?: string;
|
|
8
|
-
type?: 'script' | 'template' | 'style' | 'custom';
|
|
9
|
-
index?: number;
|
|
10
|
-
lang?: string;
|
|
11
|
-
raw?: boolean;
|
|
12
|
-
url?: boolean;
|
|
13
|
-
scoped?: boolean;
|
|
14
|
-
id?: string;
|
|
15
|
-
}
|
|
16
|
-
declare function parseVueRequest(id: string): {
|
|
17
|
-
filename: string;
|
|
18
|
-
query: VueQuery;
|
|
19
|
-
};
|
|
20
|
-
|
|
21
|
-
interface Options {
|
|
22
|
-
include?: string | RegExp | (string | RegExp)[];
|
|
23
|
-
exclude?: string | RegExp | (string | RegExp)[];
|
|
24
|
-
/**
|
|
25
|
-
* In Vite, this option follows Vite's config.
|
|
26
|
-
*/
|
|
27
|
-
isProduction?: boolean;
|
|
28
|
-
script?: Partial<Omit<SFCScriptCompileOptions, 'id' | 'isProd' | 'inlineTemplate' | 'templateOptions' | 'sourceMap' | 'genDefaultAs' | 'customElement' | 'defineModel' | 'propsDestructure'>> & {
|
|
29
|
-
/**
|
|
30
|
-
* @deprecated defineModel is now a stable feature and always enabled if
|
|
31
|
-
* using Vue 3.4 or above.
|
|
32
|
-
*/
|
|
33
|
-
defineModel?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* @deprecated moved to `features.propsDestructure`.
|
|
36
|
-
*/
|
|
37
|
-
propsDestructure?: boolean;
|
|
38
|
-
};
|
|
39
|
-
template?: Partial<Omit<SFCTemplateCompileOptions, 'id' | 'source' | 'ast' | 'filename' | 'scoped' | 'slotted' | 'isProd' | 'inMap' | 'ssr' | 'ssrCssVars' | 'preprocessLang'>>;
|
|
40
|
-
style?: Partial<Omit<SFCStyleCompileOptions, 'filename' | 'id' | 'isProd' | 'source' | 'scoped' | 'cssDevSourcemap' | 'postcssOptions' | 'map' | 'postcssPlugins' | 'preprocessCustomRequire' | 'preprocessLang' | 'preprocessOptions'>>;
|
|
41
|
-
/**
|
|
42
|
-
* Use custom compiler-sfc instance. Can be used to force a specific version.
|
|
43
|
-
*/
|
|
44
|
-
compiler?: typeof _compiler;
|
|
45
|
-
/**
|
|
46
|
-
* Requires @vitejs/plugin-vue@^5.1.0
|
|
47
|
-
*/
|
|
48
|
-
features?: {
|
|
49
|
-
/**
|
|
50
|
-
* Enable reactive destructure for `defineProps`.
|
|
51
|
-
* - Available in Vue 3.4 and later.
|
|
52
|
-
* - **default:** `false` in Vue 3.4 (**experimental**), `true` in Vue 3.5+
|
|
53
|
-
*/
|
|
54
|
-
propsDestructure?: boolean;
|
|
55
|
-
/**
|
|
56
|
-
* Transform Vue SFCs into custom elements.
|
|
57
|
-
* - `true`: all `*.vue` imports are converted into custom elements
|
|
58
|
-
* - `string | RegExp`: matched files are converted into custom elements
|
|
59
|
-
* - **default:** /\.ce\.vue$/
|
|
60
|
-
*/
|
|
61
|
-
customElement?: boolean | string | RegExp | (string | RegExp)[];
|
|
62
|
-
/**
|
|
63
|
-
* Set to `false` to disable Options API support and allow related code in
|
|
64
|
-
* Vue core to be dropped via dead-code elimination in production builds,
|
|
65
|
-
* resulting in smaller bundles.
|
|
66
|
-
* - **default:** `true`
|
|
67
|
-
*/
|
|
68
|
-
optionsAPI?: boolean;
|
|
69
|
-
/**
|
|
70
|
-
* Set to `true` to enable devtools support in production builds.
|
|
71
|
-
* Results in slightly larger bundles.
|
|
72
|
-
* - **default:** `false`
|
|
73
|
-
*/
|
|
74
|
-
prodDevtools?: boolean;
|
|
75
|
-
/**
|
|
76
|
-
* Set to `true` to enable detailed information for hydration mismatch
|
|
77
|
-
* errors in production builds. Results in slightly larger bundles.
|
|
78
|
-
* - **default:** `false`
|
|
79
|
-
*/
|
|
80
|
-
prodHydrationMismatchDetails?: boolean;
|
|
81
|
-
/**
|
|
82
|
-
* Customize the component ID generation strategy.
|
|
83
|
-
* - `'filepath'`: hash the file path (relative to the project root)
|
|
84
|
-
* - `'filepath-source'`: hash the file path and the source code
|
|
85
|
-
* - `function`: custom function that takes the file path, source code,
|
|
86
|
-
* whether in production mode, and the default hash function as arguments
|
|
87
|
-
* - **default:** `'filepath'` in development, `'filepath-source'` in production
|
|
88
|
-
*/
|
|
89
|
-
componentIdGenerator?: 'filepath' | 'filepath-source' | ((filepath: string, source: string, isProduction: boolean | undefined, getHash: (text: string) => string) => string);
|
|
90
|
-
};
|
|
91
|
-
/**
|
|
92
|
-
* @deprecated moved to `features.customElement`.
|
|
93
|
-
*/
|
|
94
|
-
customElement?: boolean | string | RegExp | (string | RegExp)[];
|
|
95
|
-
}
|
|
96
|
-
interface ResolvedOptions extends Options {
|
|
97
|
-
compiler: typeof _compiler;
|
|
98
|
-
root: string;
|
|
99
|
-
sourceMap: boolean;
|
|
100
|
-
cssDevSourcemap: boolean;
|
|
101
|
-
devServer?: ViteDevServer;
|
|
102
|
-
devToolsEnabled?: boolean;
|
|
103
|
-
}
|
|
104
|
-
interface Api {
|
|
105
|
-
get options(): ResolvedOptions;
|
|
106
|
-
set options(value: ResolvedOptions);
|
|
107
|
-
version: string;
|
|
108
|
-
}
|
|
109
|
-
declare function vuePlugin(rawOptions?: Options): Plugin<Api>;
|
|
110
|
-
|
|
111
|
-
export { type Api, type Options, type ResolvedOptions, type VueQuery, vuePlugin as default, parseVueRequest };
|
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
import { Plugin, ViteDevServer } from 'vite';
|
|
2
|
-
import * as _compiler from 'vue/compiler-sfc';
|
|
3
|
-
import { SFCScriptCompileOptions, SFCTemplateCompileOptions, SFCStyleCompileOptions } from 'vue/compiler-sfc';
|
|
4
|
-
|
|
5
|
-
interface VueQuery {
|
|
6
|
-
vue?: boolean;
|
|
7
|
-
src?: string;
|
|
8
|
-
type?: 'script' | 'template' | 'style' | 'custom';
|
|
9
|
-
index?: number;
|
|
10
|
-
lang?: string;
|
|
11
|
-
raw?: boolean;
|
|
12
|
-
url?: boolean;
|
|
13
|
-
scoped?: boolean;
|
|
14
|
-
id?: string;
|
|
15
|
-
}
|
|
16
|
-
declare function parseVueRequest(id: string): {
|
|
17
|
-
filename: string;
|
|
18
|
-
query: VueQuery;
|
|
19
|
-
};
|
|
20
|
-
|
|
21
|
-
interface Options {
|
|
22
|
-
include?: string | RegExp | (string | RegExp)[];
|
|
23
|
-
exclude?: string | RegExp | (string | RegExp)[];
|
|
24
|
-
/**
|
|
25
|
-
* In Vite, this option follows Vite's config.
|
|
26
|
-
*/
|
|
27
|
-
isProduction?: boolean;
|
|
28
|
-
script?: Partial<Omit<SFCScriptCompileOptions, 'id' | 'isProd' | 'inlineTemplate' | 'templateOptions' | 'sourceMap' | 'genDefaultAs' | 'customElement' | 'defineModel' | 'propsDestructure'>> & {
|
|
29
|
-
/**
|
|
30
|
-
* @deprecated defineModel is now a stable feature and always enabled if
|
|
31
|
-
* using Vue 3.4 or above.
|
|
32
|
-
*/
|
|
33
|
-
defineModel?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* @deprecated moved to `features.propsDestructure`.
|
|
36
|
-
*/
|
|
37
|
-
propsDestructure?: boolean;
|
|
38
|
-
};
|
|
39
|
-
template?: Partial<Omit<SFCTemplateCompileOptions, 'id' | 'source' | 'ast' | 'filename' | 'scoped' | 'slotted' | 'isProd' | 'inMap' | 'ssr' | 'ssrCssVars' | 'preprocessLang'>>;
|
|
40
|
-
style?: Partial<Omit<SFCStyleCompileOptions, 'filename' | 'id' | 'isProd' | 'source' | 'scoped' | 'cssDevSourcemap' | 'postcssOptions' | 'map' | 'postcssPlugins' | 'preprocessCustomRequire' | 'preprocessLang' | 'preprocessOptions'>>;
|
|
41
|
-
/**
|
|
42
|
-
* Use custom compiler-sfc instance. Can be used to force a specific version.
|
|
43
|
-
*/
|
|
44
|
-
compiler?: typeof _compiler;
|
|
45
|
-
/**
|
|
46
|
-
* Requires @vitejs/plugin-vue@^5.1.0
|
|
47
|
-
*/
|
|
48
|
-
features?: {
|
|
49
|
-
/**
|
|
50
|
-
* Enable reactive destructure for `defineProps`.
|
|
51
|
-
* - Available in Vue 3.4 and later.
|
|
52
|
-
* - **default:** `false` in Vue 3.4 (**experimental**), `true` in Vue 3.5+
|
|
53
|
-
*/
|
|
54
|
-
propsDestructure?: boolean;
|
|
55
|
-
/**
|
|
56
|
-
* Transform Vue SFCs into custom elements.
|
|
57
|
-
* - `true`: all `*.vue` imports are converted into custom elements
|
|
58
|
-
* - `string | RegExp`: matched files are converted into custom elements
|
|
59
|
-
* - **default:** /\.ce\.vue$/
|
|
60
|
-
*/
|
|
61
|
-
customElement?: boolean | string | RegExp | (string | RegExp)[];
|
|
62
|
-
/**
|
|
63
|
-
* Set to `false` to disable Options API support and allow related code in
|
|
64
|
-
* Vue core to be dropped via dead-code elimination in production builds,
|
|
65
|
-
* resulting in smaller bundles.
|
|
66
|
-
* - **default:** `true`
|
|
67
|
-
*/
|
|
68
|
-
optionsAPI?: boolean;
|
|
69
|
-
/**
|
|
70
|
-
* Set to `true` to enable devtools support in production builds.
|
|
71
|
-
* Results in slightly larger bundles.
|
|
72
|
-
* - **default:** `false`
|
|
73
|
-
*/
|
|
74
|
-
prodDevtools?: boolean;
|
|
75
|
-
/**
|
|
76
|
-
* Set to `true` to enable detailed information for hydration mismatch
|
|
77
|
-
* errors in production builds. Results in slightly larger bundles.
|
|
78
|
-
* - **default:** `false`
|
|
79
|
-
*/
|
|
80
|
-
prodHydrationMismatchDetails?: boolean;
|
|
81
|
-
/**
|
|
82
|
-
* Customize the component ID generation strategy.
|
|
83
|
-
* - `'filepath'`: hash the file path (relative to the project root)
|
|
84
|
-
* - `'filepath-source'`: hash the file path and the source code
|
|
85
|
-
* - `function`: custom function that takes the file path, source code,
|
|
86
|
-
* whether in production mode, and the default hash function as arguments
|
|
87
|
-
* - **default:** `'filepath'` in development, `'filepath-source'` in production
|
|
88
|
-
*/
|
|
89
|
-
componentIdGenerator?: 'filepath' | 'filepath-source' | ((filepath: string, source: string, isProduction: boolean | undefined, getHash: (text: string) => string) => string);
|
|
90
|
-
};
|
|
91
|
-
/**
|
|
92
|
-
* @deprecated moved to `features.customElement`.
|
|
93
|
-
*/
|
|
94
|
-
customElement?: boolean | string | RegExp | (string | RegExp)[];
|
|
95
|
-
}
|
|
96
|
-
interface ResolvedOptions extends Options {
|
|
97
|
-
compiler: typeof _compiler;
|
|
98
|
-
root: string;
|
|
99
|
-
sourceMap: boolean;
|
|
100
|
-
cssDevSourcemap: boolean;
|
|
101
|
-
devServer?: ViteDevServer;
|
|
102
|
-
devToolsEnabled?: boolean;
|
|
103
|
-
}
|
|
104
|
-
interface Api {
|
|
105
|
-
get options(): ResolvedOptions;
|
|
106
|
-
set options(value: ResolvedOptions);
|
|
107
|
-
version: string;
|
|
108
|
-
}
|
|
109
|
-
declare function vuePlugin(rawOptions?: Options): Plugin<Api>;
|
|
110
|
-
|
|
111
|
-
// @ts-ignore
|
|
112
|
-
export = vuePlugin;
|
|
113
|
-
export { type Api, type Options, type ResolvedOptions, type VueQuery, parseVueRequest };
|