vite 6.0.0-beta.4 → 6.0.0-beta.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/LICENSE.md +0 -21
- package/dist/client/client.mjs +23 -16
- package/dist/node/chunks/{dep-Cq6WeEUK.js → dep-BBdZfOY1.js} +1 -1
- package/dist/node/chunks/{dep-Cpgpmu8-.js → dep-D4jOq5eU.js} +16998 -23384
- package/dist/node/chunks/{dep-BkDduZ8N.js → dep-DmJnO2SA.js} +1 -1
- package/dist/node/cli.js +5 -5
- package/dist/node/index.d.ts +45 -79
- package/dist/node/index.js +2 -2
- package/dist/node/module-runner.js +11 -5
- package/dist/node-cjs/publicUtils.cjs +80 -60
- package/package.json +24 -11
- package/types/internal/cssPreprocessorOptions.d.ts +63 -0
- package/types/internal/lightningcssOptions.d.ts +18 -0
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "vite",
|
3
|
-
"version": "6.0.0-beta.
|
3
|
+
"version": "6.0.0-beta.6",
|
4
4
|
"type": "module",
|
5
5
|
"license": "MIT",
|
6
6
|
"author": "Evan You",
|
@@ -40,6 +40,7 @@
|
|
40
40
|
"./types/*": {
|
41
41
|
"types": "./types/*"
|
42
42
|
},
|
43
|
+
"./types/internal/*": null,
|
43
44
|
"./package.json": "./package.json"
|
44
45
|
},
|
45
46
|
"typesVersions": {
|
@@ -74,22 +75,22 @@
|
|
74
75
|
"dependencies": {
|
75
76
|
"esbuild": "^0.24.0",
|
76
77
|
"postcss": "^8.4.47",
|
77
|
-
"rollup": "^4.
|
78
|
+
"rollup": "^4.23.0"
|
78
79
|
},
|
79
80
|
"optionalDependencies": {
|
80
81
|
"fsevents": "~2.3.3"
|
81
82
|
},
|
82
83
|
"devDependencies": {
|
83
84
|
"@ampproject/remapping": "^2.3.0",
|
84
|
-
"@babel/parser": "^7.
|
85
|
+
"@babel/parser": "^7.26.1",
|
85
86
|
"@jridgewell/trace-mapping": "^0.3.25",
|
86
87
|
"@polka/compression": "^1.0.0-next.25",
|
87
88
|
"@rollup/plugin-alias": "^5.1.1",
|
88
89
|
"@rollup/plugin-commonjs": "^28.0.1",
|
89
|
-
"@rollup/plugin-dynamic-import-vars": "
|
90
|
+
"@rollup/plugin-dynamic-import-vars": "2.1.4",
|
90
91
|
"@rollup/plugin-json": "^6.1.0",
|
91
92
|
"@rollup/plugin-node-resolve": "15.3.0",
|
92
|
-
"@rollup/pluginutils": "^5.1.
|
93
|
+
"@rollup/pluginutils": "^5.1.3",
|
93
94
|
"@types/escape-html": "^1.0.4",
|
94
95
|
"@types/pnpapi": "^0.0.5",
|
95
96
|
"artichokie": "^0.2.1",
|
@@ -120,21 +121,21 @@
|
|
120
121
|
"pathe": "^1.1.2",
|
121
122
|
"periscopic": "^4.0.2",
|
122
123
|
"picocolors": "^1.1.1",
|
123
|
-
"picomatch": "^
|
124
|
+
"picomatch": "^4.0.2",
|
124
125
|
"postcss-import": "^16.1.0",
|
125
|
-
"postcss-load-config": "^
|
126
|
+
"postcss-load-config": "^6.0.1",
|
126
127
|
"postcss-modules": "^6.0.0",
|
127
128
|
"resolve.exports": "^2.0.2",
|
128
129
|
"rollup-plugin-dts": "^6.1.1",
|
129
130
|
"rollup-plugin-esbuild": "^6.1.1",
|
130
131
|
"rollup-plugin-license": "^3.5.3",
|
131
|
-
"sass": "^1.80.
|
132
|
-
"sass-embedded": "^1.80.
|
132
|
+
"sass": "^1.80.4",
|
133
|
+
"sass-embedded": "^1.80.4",
|
133
134
|
"sirv": "^3.0.0",
|
134
135
|
"source-map-support": "^0.5.21",
|
135
136
|
"strip-ansi": "^7.1.0",
|
136
137
|
"strip-literal": "^2.1.0",
|
137
|
-
"tinyglobby": "^0.2.
|
138
|
+
"tinyglobby": "^0.2.10",
|
138
139
|
"tsconfck": "^3.1.4",
|
139
140
|
"tslib": "^2.8.0",
|
140
141
|
"types": "link:./types",
|
@@ -143,18 +144,24 @@
|
|
143
144
|
},
|
144
145
|
"peerDependencies": {
|
145
146
|
"@types/node": "^18.0.0 || >=20.0.0",
|
147
|
+
"jiti": ">=1.21.0",
|
146
148
|
"less": "*",
|
147
149
|
"lightningcss": "^1.21.0",
|
148
150
|
"sass": "*",
|
149
151
|
"sass-embedded": "*",
|
150
152
|
"stylus": "*",
|
151
153
|
"sugarss": "*",
|
152
|
-
"terser": "^5.16.0"
|
154
|
+
"terser": "^5.16.0",
|
155
|
+
"tsx": "^4.8.1",
|
156
|
+
"yaml": "^2.4.2"
|
153
157
|
},
|
154
158
|
"peerDependenciesMeta": {
|
155
159
|
"@types/node": {
|
156
160
|
"optional": true
|
157
161
|
},
|
162
|
+
"jiti": {
|
163
|
+
"optional": true
|
164
|
+
},
|
158
165
|
"sass": {
|
159
166
|
"optional": true
|
160
167
|
},
|
@@ -175,6 +182,12 @@
|
|
175
182
|
},
|
176
183
|
"terser": {
|
177
184
|
"optional": true
|
185
|
+
},
|
186
|
+
"tsx": {
|
187
|
+
"optional": true
|
188
|
+
},
|
189
|
+
"yaml": {
|
190
|
+
"optional": true
|
178
191
|
}
|
179
192
|
},
|
180
193
|
"scripts": {
|
@@ -0,0 +1,63 @@
|
|
1
|
+
/* eslint-disable @typescript-eslint/ban-ts-comment */
|
2
|
+
|
3
|
+
// @ts-ignore `sass` may not be installed
|
4
|
+
import type DartSass from 'sass'
|
5
|
+
// @ts-ignore `sass-embedded` may not be installed
|
6
|
+
import type SassEmbedded from 'sass-embedded'
|
7
|
+
// @ts-ignore `less` may not be installed
|
8
|
+
import type Less from 'less'
|
9
|
+
// @ts-ignore `less` may not be installed
|
10
|
+
import type Stylus from 'stylus'
|
11
|
+
|
12
|
+
/* eslint-enable @typescript-eslint/ban-ts-comment */
|
13
|
+
|
14
|
+
// https://github.com/type-challenges/type-challenges/issues/29285
|
15
|
+
type IsAny<T> = boolean extends (T extends never ? true : false) ? true : false
|
16
|
+
|
17
|
+
type DartSassLegacyStringOptionsAsync = DartSass.LegacyStringOptions<'async'>
|
18
|
+
type SassEmbeddedLegacyStringOptionsAsync =
|
19
|
+
SassEmbedded.LegacyStringOptions<'async'>
|
20
|
+
type SassLegacyStringOptionsAsync =
|
21
|
+
IsAny<DartSassLegacyStringOptionsAsync> extends false
|
22
|
+
? DartSassLegacyStringOptionsAsync
|
23
|
+
: SassEmbeddedLegacyStringOptionsAsync
|
24
|
+
|
25
|
+
export type SassLegacyPreprocessBaseOptions = Omit<
|
26
|
+
SassLegacyStringOptionsAsync,
|
27
|
+
| 'data'
|
28
|
+
| 'file'
|
29
|
+
| 'outFile'
|
30
|
+
| 'sourceMap'
|
31
|
+
| 'omitSourceMapUrl'
|
32
|
+
| 'sourceMapEmbed'
|
33
|
+
| 'sourceMapRoot'
|
34
|
+
>
|
35
|
+
|
36
|
+
type DartSassStringOptionsAsync = DartSass.StringOptions<'async'>
|
37
|
+
type SassEmbeddedStringOptionsAsync = SassEmbedded.StringOptions<'async'>
|
38
|
+
type SassStringOptionsAsync =
|
39
|
+
IsAny<DartSassStringOptionsAsync> extends false
|
40
|
+
? DartSassStringOptionsAsync
|
41
|
+
: SassEmbeddedStringOptionsAsync
|
42
|
+
|
43
|
+
export type SassModernPreprocessBaseOptions = Omit<
|
44
|
+
SassStringOptionsAsync,
|
45
|
+
'url' | 'sourceMap'
|
46
|
+
>
|
47
|
+
|
48
|
+
export type LessPreprocessorBaseOptions = Omit<
|
49
|
+
Less.Options,
|
50
|
+
'sourceMap' | 'filename'
|
51
|
+
>
|
52
|
+
|
53
|
+
export type StylusPreprocessorBaseOptions = Omit<
|
54
|
+
Stylus.RenderOptions,
|
55
|
+
'filename'
|
56
|
+
> & { define?: Record<string, any> }
|
57
|
+
|
58
|
+
declare global {
|
59
|
+
// LESS' types somewhat references this which doesn't make sense in Node,
|
60
|
+
// so we have to shim it
|
61
|
+
// eslint-disable-next-line @typescript-eslint/no-empty-object-type
|
62
|
+
interface HTMLLinkElement {}
|
63
|
+
}
|
@@ -0,0 +1,18 @@
|
|
1
|
+
/* eslint-disable @typescript-eslint/ban-ts-comment */
|
2
|
+
|
3
|
+
// @ts-ignore `sass` may not be installed
|
4
|
+
import type Lightningcss from 'lightningcss'
|
5
|
+
|
6
|
+
/* eslint-enable @typescript-eslint/ban-ts-comment */
|
7
|
+
|
8
|
+
export type LightningCSSOptions = Omit<
|
9
|
+
Lightningcss.BundleAsyncOptions<Lightningcss.CustomAtRules>,
|
10
|
+
| 'filename'
|
11
|
+
| 'resolver'
|
12
|
+
| 'minify'
|
13
|
+
| 'sourceMap'
|
14
|
+
| 'analyzeDependencies'
|
15
|
+
// properties not overridden by Vite, but does not make sense to set by end users
|
16
|
+
| 'inputSourceMap'
|
17
|
+
| 'projectRoot'
|
18
|
+
>
|