vite 8.0.0-beta.9 → 8.0.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/LICENSE.md +237 -116
- package/dist/client/client.mjs +121 -24
- package/dist/client/env.mjs +1 -2
- package/dist/node/chunks/build.js +2 -3
- package/dist/node/chunks/build2.js +148 -309
- package/dist/node/chunks/chunk.js +14 -24
- package/dist/node/chunks/config.js +2 -3
- package/dist/node/chunks/dist.js +34 -73
- package/dist/node/chunks/lib.js +1 -7
- package/dist/node/chunks/logger.js +1 -5
- package/dist/node/chunks/moduleRunnerTransport.d.ts +23 -23
- package/dist/node/chunks/node.js +2717 -4245
- package/dist/node/chunks/optimizer.js +2 -3
- package/dist/node/chunks/postcss-import.js +11 -23
- package/dist/node/chunks/preview.js +2 -3
- package/dist/node/chunks/server.js +2 -3
- package/dist/node/cli.js +211 -73
- package/dist/node/index.d.ts +1523 -1488
- package/dist/node/index.js +2 -3
- package/dist/node/internal.js +1 -2
- package/dist/node/module-runner.d.ts +79 -75
- package/dist/node/module-runner.js +112 -11
- package/package.json +27 -27
- package/types/customEvent.d.ts +27 -0
- package/types/metadata.d.ts +9 -0
package/LICENSE.md
CHANGED
|
@@ -25,7 +25,7 @@ SOFTWARE.
|
|
|
25
25
|
|
|
26
26
|
# Licenses of bundled dependencies
|
|
27
27
|
The published Vite artifact additionally contains code with the following licenses:
|
|
28
|
-
BSD-2-Clause, CC0-1.0, ISC, MIT
|
|
28
|
+
Apache-2.0, BSD-2-Clause, CC0-1.0, ISC, MIT
|
|
29
29
|
|
|
30
30
|
# Bundled dependencies:
|
|
31
31
|
## @jridgewell/gen-mapping, @jridgewell/remapping, @jridgewell/sourcemap-codec, @jridgewell/trace-mapping
|
|
@@ -95,13 +95,22 @@ Repository: https://github.com/lukeed/polka
|
|
|
95
95
|
|
|
96
96
|
---------------------------------------
|
|
97
97
|
|
|
98
|
-
## @
|
|
98
|
+
## @rollup/plugin-alias, @rollup/plugin-dynamic-import-vars, @rollup/pluginutils
|
|
99
99
|
License: MIT
|
|
100
|
-
|
|
100
|
+
By: Johannes Stein
|
|
101
|
+
Repository: https://github.com/rollup/plugins
|
|
101
102
|
|
|
102
|
-
|
|
103
|
+
License: MIT
|
|
104
|
+
By: LarsDenBakker
|
|
105
|
+
Repository: https://github.com/rollup/plugins
|
|
106
|
+
|
|
107
|
+
License: MIT
|
|
108
|
+
By: Rich Harris
|
|
109
|
+
Repository: https://github.com/rollup/plugins
|
|
110
|
+
|
|
111
|
+
> The MIT License (MIT)
|
|
103
112
|
>
|
|
104
|
-
> Copyright (c)
|
|
113
|
+
> Copyright (c) 2019 RollupJS Plugin Contributors (https://github.com/rollup/plugins/graphs/contributors)
|
|
105
114
|
>
|
|
106
115
|
> Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
107
116
|
> of this software and associated documentation files (the "Software"), to deal
|
|
@@ -110,39 +119,235 @@ Repository: https://github.com/rolldown/rolldown
|
|
|
110
119
|
> copies of the Software, and to permit persons to whom the Software is
|
|
111
120
|
> furnished to do so, subject to the following conditions:
|
|
112
121
|
>
|
|
113
|
-
> The above copyright notice and this permission notice shall be included in
|
|
114
|
-
> copies or substantial portions of the Software.
|
|
122
|
+
> The above copyright notice and this permission notice shall be included in
|
|
123
|
+
> all copies or substantial portions of the Software.
|
|
115
124
|
>
|
|
116
125
|
> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
117
126
|
> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
118
127
|
> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
119
128
|
> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
120
129
|
> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
121
|
-
> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
122
|
-
> SOFTWARE.
|
|
123
|
-
>
|
|
124
|
-
> end of terms and conditions
|
|
125
|
-
>
|
|
126
|
-
> The licenses of externally maintained libraries from which parts of the Software is derived are listed [here](https://github.com/rolldown/rolldown/blob/main/THIRD-PARTY-LICENSE).
|
|
130
|
+
> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
131
|
+
> THE SOFTWARE.
|
|
127
132
|
|
|
128
133
|
---------------------------------------
|
|
129
134
|
|
|
130
|
-
## @
|
|
131
|
-
License:
|
|
132
|
-
By:
|
|
133
|
-
Repository: https://github.com/
|
|
135
|
+
## @vercel/detect-agent
|
|
136
|
+
License: Apache-2.0
|
|
137
|
+
By: Vercel
|
|
138
|
+
Repository: https://github.com/vercel/vercel
|
|
139
|
+
|
|
140
|
+
> Apache License
|
|
141
|
+
> Version 2.0, January 2004
|
|
142
|
+
> http://www.apache.org/licenses/
|
|
143
|
+
>
|
|
144
|
+
> TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
145
|
+
>
|
|
146
|
+
> 1. Definitions.
|
|
147
|
+
>
|
|
148
|
+
> "License" shall mean the terms and conditions for use, reproduction,
|
|
149
|
+
> and distribution as defined by Sections 1 through 9 of this document.
|
|
150
|
+
>
|
|
151
|
+
> "Licensor" shall mean the copyright owner or entity authorized by
|
|
152
|
+
> the copyright owner that is granting the License.
|
|
153
|
+
>
|
|
154
|
+
> "Legal Entity" shall mean the union of the acting entity and all
|
|
155
|
+
> other entities that control, are controlled by, or are under common
|
|
156
|
+
> control with that entity. For the purposes of this definition,
|
|
157
|
+
> "control" means (i) the power, direct or indirect, to cause the
|
|
158
|
+
> direction or management of such entity, whether by contract or
|
|
159
|
+
> otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
160
|
+
> outstanding shares, or (iii) beneficial ownership of such entity.
|
|
161
|
+
>
|
|
162
|
+
> "You" (or "Your") shall mean an individual or Legal Entity
|
|
163
|
+
> exercising permissions granted by this License.
|
|
164
|
+
>
|
|
165
|
+
> "Source" form shall mean the preferred form for making modifications,
|
|
166
|
+
> including but not limited to software source code, documentation
|
|
167
|
+
> source, and configuration files.
|
|
168
|
+
>
|
|
169
|
+
> "Object" form shall mean any form resulting from mechanical
|
|
170
|
+
> transformation or translation of a Source form, including but
|
|
171
|
+
> not limited to compiled object code, generated documentation,
|
|
172
|
+
> and conversions to other media types.
|
|
173
|
+
>
|
|
174
|
+
> "Work" shall mean the work of authorship, whether in Source or
|
|
175
|
+
> Object form, made available under the License, as indicated by a
|
|
176
|
+
> copyright notice that is included in or attached to the work
|
|
177
|
+
> (an example is provided in the Appendix below).
|
|
178
|
+
>
|
|
179
|
+
> "Derivative Works" shall mean any work, whether in Source or Object
|
|
180
|
+
> form, that is based on (or derived from) the Work and for which the
|
|
181
|
+
> editorial revisions, annotations, elaborations, or other modifications
|
|
182
|
+
> represent, as a whole, an original work of authorship. For the purposes
|
|
183
|
+
> of this License, Derivative Works shall not include works that remain
|
|
184
|
+
> separable from, or merely link (or bind by name) to the interfaces of,
|
|
185
|
+
> the Work and Derivative Works thereof.
|
|
186
|
+
>
|
|
187
|
+
> "Contribution" shall mean any work of authorship, including
|
|
188
|
+
> the original version of the Work and any modifications or additions
|
|
189
|
+
> to that Work or Derivative Works thereof, that is intentionally
|
|
190
|
+
> submitted to Licensor for inclusion in the Work by the copyright owner
|
|
191
|
+
> or by an individual or Legal Entity authorized to submit on behalf of
|
|
192
|
+
> the copyright owner. For the purposes of this definition, "submitted"
|
|
193
|
+
> means any form of electronic, verbal, or written communication sent
|
|
194
|
+
> to the Licensor or its representatives, including but not limited to
|
|
195
|
+
> communication on electronic mailing lists, source code control systems,
|
|
196
|
+
> and issue tracking systems that are managed by, or on behalf of, the
|
|
197
|
+
> Licensor for the purpose of discussing and improving the Work, but
|
|
198
|
+
> excluding communication that is conspicuously marked or otherwise
|
|
199
|
+
> designated in writing by the copyright owner as "Not a Contribution."
|
|
200
|
+
>
|
|
201
|
+
> "Contributor" shall mean Licensor and any individual or Legal Entity
|
|
202
|
+
> on behalf of whom a Contribution has been received by Licensor and
|
|
203
|
+
> subsequently incorporated within the Work.
|
|
204
|
+
>
|
|
205
|
+
> 2. Grant of Copyright License. Subject to the terms and conditions of
|
|
206
|
+
> this License, each Contributor hereby grants to You a perpetual,
|
|
207
|
+
> worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
208
|
+
> copyright license to reproduce, prepare Derivative Works of,
|
|
209
|
+
> publicly display, publicly perform, sublicense, and distribute the
|
|
210
|
+
> Work and such Derivative Works in Source or Object form.
|
|
211
|
+
>
|
|
212
|
+
> 3. Grant of Patent License. Subject to the terms and conditions of
|
|
213
|
+
> this License, each Contributor hereby grants to You a perpetual,
|
|
214
|
+
> worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
215
|
+
> (except as stated in this section) patent license to make, have made,
|
|
216
|
+
> use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
217
|
+
> where such license applies only to those patent claims licensable
|
|
218
|
+
> by such Contributor that are necessarily infringed by their
|
|
219
|
+
> Contribution(s) alone or by combination of their Contribution(s)
|
|
220
|
+
> with the Work to which such Contribution(s) was submitted. If You
|
|
221
|
+
> institute patent litigation against any entity (including a
|
|
222
|
+
> cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
223
|
+
> or a Contribution incorporated within the Work constitutes direct
|
|
224
|
+
> or contributory patent infringement, then any patent licenses
|
|
225
|
+
> granted to You under this License for that Work shall terminate
|
|
226
|
+
> as of the date such litigation is filed.
|
|
227
|
+
>
|
|
228
|
+
> 4. Redistribution. You may reproduce and distribute copies of the
|
|
229
|
+
> Work or Derivative Works thereof in any medium, with or without
|
|
230
|
+
> modifications, and in Source or Object form, provided that You
|
|
231
|
+
> meet the following conditions:
|
|
232
|
+
>
|
|
233
|
+
> (a) You must give any other recipients of the Work or
|
|
234
|
+
> Derivative Works a copy of this License; and
|
|
235
|
+
>
|
|
236
|
+
> (b) You must cause any modified files to carry prominent notices
|
|
237
|
+
> stating that You changed the files; and
|
|
238
|
+
>
|
|
239
|
+
> (c) You must retain, in the Source form of any Derivative Works
|
|
240
|
+
> that You distribute, all copyright, patent, trademark, and
|
|
241
|
+
> attribution notices from the Source form of the Work,
|
|
242
|
+
> excluding those notices that do not pertain to any part of
|
|
243
|
+
> the Derivative Works; and
|
|
244
|
+
>
|
|
245
|
+
> (d) If the Work includes a "NOTICE" text file as part of its
|
|
246
|
+
> distribution, then any Derivative Works that You distribute must
|
|
247
|
+
> include a readable copy of the attribution notices contained
|
|
248
|
+
> within such NOTICE file, excluding those notices that do not
|
|
249
|
+
> pertain to any part of the Derivative Works, in at least one
|
|
250
|
+
> of the following places: within a NOTICE text file distributed
|
|
251
|
+
> as part of the Derivative Works; within the Source form or
|
|
252
|
+
> documentation, if provided along with the Derivative Works; or,
|
|
253
|
+
> within a display generated by the Derivative Works, if and
|
|
254
|
+
> wherever such third-party notices normally appear. The contents
|
|
255
|
+
> of the NOTICE file are for informational purposes only and
|
|
256
|
+
> do not modify the License. You may add Your own attribution
|
|
257
|
+
> notices within Derivative Works that You distribute, alongside
|
|
258
|
+
> or as an addendum to the NOTICE text from the Work, provided
|
|
259
|
+
> that such additional attribution notices cannot be construed
|
|
260
|
+
> as modifying the License.
|
|
261
|
+
>
|
|
262
|
+
> You may add Your own copyright statement to Your modifications and
|
|
263
|
+
> may provide additional or different license terms and conditions
|
|
264
|
+
> for use, reproduction, or distribution of Your modifications, or
|
|
265
|
+
> for any such Derivative Works as a whole, provided Your use,
|
|
266
|
+
> reproduction, and distribution of the Work otherwise complies with
|
|
267
|
+
> the conditions stated in this License.
|
|
268
|
+
>
|
|
269
|
+
> 5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
270
|
+
> any Contribution intentionally submitted for inclusion in the Work
|
|
271
|
+
> by You to the Licensor shall be under the terms and conditions of
|
|
272
|
+
> this License, without any additional terms or conditions.
|
|
273
|
+
> Notwithstanding the above, nothing herein shall supersede or modify
|
|
274
|
+
> the terms of any separate license agreement you may have executed
|
|
275
|
+
> with Licensor regarding such Contributions.
|
|
276
|
+
>
|
|
277
|
+
> 6. Trademarks. This License does not grant permission to use the trade
|
|
278
|
+
> names, trademarks, service marks, or product names of the Licensor,
|
|
279
|
+
> except as required for reasonable and customary use in describing the
|
|
280
|
+
> origin of the Work and reproducing the content of the NOTICE file.
|
|
281
|
+
>
|
|
282
|
+
> 7. Disclaimer of Warranty. Unless required by applicable law or
|
|
283
|
+
> agreed to in writing, Licensor provides the Work (and each
|
|
284
|
+
> Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
285
|
+
> WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
286
|
+
> implied, including, without limitation, any warranties or conditions
|
|
287
|
+
> of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
288
|
+
> PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
289
|
+
> appropriateness of using or redistributing the Work and assume any
|
|
290
|
+
> risks associated with Your exercise of permissions under this License.
|
|
291
|
+
>
|
|
292
|
+
> 8. Limitation of Liability. In no event and under no legal theory,
|
|
293
|
+
> whether in tort (including negligence), contract, or otherwise,
|
|
294
|
+
> unless required by applicable law (such as deliberate and grossly
|
|
295
|
+
> negligent acts) or agreed to in writing, shall any Contributor be
|
|
296
|
+
> liable to You for damages, including any direct, indirect, special,
|
|
297
|
+
> incidental, or consequential damages of any character arising as a
|
|
298
|
+
> result of this License or out of the use or inability to use the
|
|
299
|
+
> Work (including but not limited to damages for loss of goodwill,
|
|
300
|
+
> work stoppage, computer failure or malfunction, or any and all
|
|
301
|
+
> other commercial damages or losses), even if such Contributor
|
|
302
|
+
> has been advised of the possibility of such damages.
|
|
303
|
+
>
|
|
304
|
+
> 9. Accepting Warranty or Additional Liability. While redistributing
|
|
305
|
+
> the Work or Derivative Works thereof, You may choose to offer,
|
|
306
|
+
> and charge a fee for, acceptance of support, warranty, indemnity,
|
|
307
|
+
> or other liability obligations and/or rights consistent with this
|
|
308
|
+
> License. However, in accepting such obligations, You may act only
|
|
309
|
+
> on Your own behalf and on Your sole responsibility, not on behalf
|
|
310
|
+
> of any other Contributor, and only if You agree to indemnify,
|
|
311
|
+
> defend, and hold each Contributor harmless for any liability
|
|
312
|
+
> incurred by, or claims asserted against, such Contributor by reason
|
|
313
|
+
> of your accepting any such warranty or additional liability.
|
|
314
|
+
>
|
|
315
|
+
> END OF TERMS AND CONDITIONS
|
|
316
|
+
>
|
|
317
|
+
> APPENDIX: How to apply the Apache License to your work.
|
|
318
|
+
>
|
|
319
|
+
> To apply the Apache License to your work, attach the following
|
|
320
|
+
> boilerplate notice, with the fields enclosed by brackets "[]"
|
|
321
|
+
> replaced with your own identifying information. (Don't include
|
|
322
|
+
> the brackets!) The text should be enclosed in the appropriate
|
|
323
|
+
> comment syntax for the file format. We also recommend that a
|
|
324
|
+
> file or class name and description of purpose be included on the
|
|
325
|
+
> same "printed page" as the copyright notice for easier
|
|
326
|
+
> identification within third-party archives.
|
|
327
|
+
>
|
|
328
|
+
> Copyright 2017 Vercel, Inc.
|
|
329
|
+
>
|
|
330
|
+
> Licensed under the Apache License, Version 2.0 (the "License");
|
|
331
|
+
> you may not use this file except in compliance with the License.
|
|
332
|
+
> You may obtain a copy of the License at
|
|
333
|
+
>
|
|
334
|
+
> http://www.apache.org/licenses/LICENSE-2.0
|
|
335
|
+
>
|
|
336
|
+
> Unless required by applicable law or agreed to in writing, software
|
|
337
|
+
> distributed under the License is distributed on an "AS IS" BASIS,
|
|
338
|
+
> WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
339
|
+
> See the License for the specific language governing permissions and
|
|
340
|
+
> limitations under the License.
|
|
341
|
+
|
|
342
|
+
---------------------------------------
|
|
343
|
+
|
|
344
|
+
## @vitest/utils
|
|
345
|
+
License: MIT
|
|
346
|
+
Repository: https://github.com/vitest-dev/vitest
|
|
134
347
|
|
|
135
|
-
|
|
136
|
-
By: LarsDenBakker
|
|
137
|
-
Repository: https://github.com/rollup/plugins
|
|
138
|
-
|
|
139
|
-
License: MIT
|
|
140
|
-
By: Rich Harris
|
|
141
|
-
Repository: https://github.com/rollup/plugins
|
|
142
|
-
|
|
143
|
-
> The MIT License (MIT)
|
|
348
|
+
> MIT License
|
|
144
349
|
>
|
|
145
|
-
> Copyright (c)
|
|
350
|
+
> Copyright (c) 2021-Present VoidZero Inc. and Vitest contributors
|
|
146
351
|
>
|
|
147
352
|
> Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
148
353
|
> of this software and associated documentation files (the "Software"), to deal
|
|
@@ -151,16 +356,16 @@ Repository: https://github.com/rollup/plugins
|
|
|
151
356
|
> copies of the Software, and to permit persons to whom the Software is
|
|
152
357
|
> furnished to do so, subject to the following conditions:
|
|
153
358
|
>
|
|
154
|
-
> The above copyright notice and this permission notice shall be included in
|
|
155
|
-
>
|
|
359
|
+
> The above copyright notice and this permission notice shall be included in all
|
|
360
|
+
> copies or substantial portions of the Software.
|
|
156
361
|
>
|
|
157
362
|
> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
158
363
|
> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
159
364
|
> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
160
365
|
> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
161
366
|
> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
162
|
-
> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
163
|
-
>
|
|
367
|
+
> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
368
|
+
> SOFTWARE.
|
|
164
369
|
|
|
165
370
|
---------------------------------------
|
|
166
371
|
|
|
@@ -292,7 +497,7 @@ Repositories: https://github.com/sindresorhus/bundle-name, https://github.com/si
|
|
|
292
497
|
## cac
|
|
293
498
|
License: MIT
|
|
294
499
|
By: egoist
|
|
295
|
-
Repository: https://github.com/
|
|
500
|
+
Repository: https://github.com/cacjs/cac
|
|
296
501
|
|
|
297
502
|
> The MIT License (MIT)
|
|
298
503
|
>
|
|
@@ -498,36 +703,6 @@ Repository: https://github.com/mathiasbynens/cssesc
|
|
|
498
703
|
|
|
499
704
|
---------------------------------------
|
|
500
705
|
|
|
501
|
-
## dotenv
|
|
502
|
-
License: BSD-2-Clause
|
|
503
|
-
Repository: https://github.com/motdotla/dotenv
|
|
504
|
-
|
|
505
|
-
> Copyright (c) 2015, Scott Motte
|
|
506
|
-
> All rights reserved.
|
|
507
|
-
>
|
|
508
|
-
> Redistribution and use in source and binary forms, with or without
|
|
509
|
-
> modification, are permitted provided that the following conditions are met:
|
|
510
|
-
>
|
|
511
|
-
> * Redistributions of source code must retain the above copyright notice, this
|
|
512
|
-
> list of conditions and the following disclaimer.
|
|
513
|
-
>
|
|
514
|
-
> * Redistributions in binary form must reproduce the above copyright notice,
|
|
515
|
-
> this list of conditions and the following disclaimer in the documentation
|
|
516
|
-
> and/or other materials provided with the distribution.
|
|
517
|
-
>
|
|
518
|
-
> THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
519
|
-
> AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
520
|
-
> IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
521
|
-
> DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
|
522
|
-
> FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
523
|
-
> DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
524
|
-
> SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
|
525
|
-
> CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
|
526
|
-
> OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
527
|
-
> OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
528
|
-
|
|
529
|
-
---------------------------------------
|
|
530
|
-
|
|
531
706
|
## dotenv-expand
|
|
532
707
|
License: BSD-2-Clause
|
|
533
708
|
By: motdotla
|
|
@@ -1908,60 +2083,6 @@ Repository: https://github.com/micromatch/to-regex-range
|
|
|
1908
2083
|
|
|
1909
2084
|
---------------------------------------
|
|
1910
2085
|
|
|
1911
|
-
## tsconfck
|
|
1912
|
-
License: MIT
|
|
1913
|
-
By: dominikg
|
|
1914
|
-
Repository: https://github.com/dominikg/tsconfck
|
|
1915
|
-
|
|
1916
|
-
> MIT License
|
|
1917
|
-
>
|
|
1918
|
-
> Copyright (c) 2021-present dominikg and [contributors](https://github.com/dominikg/tsconfck/graphs/contributors)
|
|
1919
|
-
>
|
|
1920
|
-
> Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
1921
|
-
> of this software and associated documentation files (the "Software"), to deal
|
|
1922
|
-
> in the Software without restriction, including without limitation the rights
|
|
1923
|
-
> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
1924
|
-
> copies of the Software, and to permit persons to whom the Software is
|
|
1925
|
-
> furnished to do so, subject to the following conditions:
|
|
1926
|
-
>
|
|
1927
|
-
> The above copyright notice and this permission notice shall be included in all
|
|
1928
|
-
> copies or substantial portions of the Software.
|
|
1929
|
-
>
|
|
1930
|
-
> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
1931
|
-
> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
1932
|
-
> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
1933
|
-
> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
1934
|
-
> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
1935
|
-
> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
1936
|
-
> SOFTWARE.
|
|
1937
|
-
>
|
|
1938
|
-
> -- Licenses for 3rd-party code included in tsconfck --
|
|
1939
|
-
>
|
|
1940
|
-
> # strip-bom and strip-json-comments
|
|
1941
|
-
> MIT License
|
|
1942
|
-
>
|
|
1943
|
-
> Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (https://sindresorhus.com)
|
|
1944
|
-
>
|
|
1945
|
-
> Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
1946
|
-
> of this software and associated documentation files (the "Software"), to deal
|
|
1947
|
-
> in the Software without restriction, including without limitation the rights
|
|
1948
|
-
> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
1949
|
-
> copies of the Software, and to permit persons to whom the Software is
|
|
1950
|
-
> furnished to do so, subject to the following conditions:
|
|
1951
|
-
>
|
|
1952
|
-
> The above copyright notice and this permission notice shall be included in all
|
|
1953
|
-
> copies or substantial portions of the Software.
|
|
1954
|
-
>
|
|
1955
|
-
> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
1956
|
-
> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
1957
|
-
> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
1958
|
-
> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
1959
|
-
> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
1960
|
-
> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
1961
|
-
> SOFTWARE.
|
|
1962
|
-
|
|
1963
|
-
---------------------------------------
|
|
1964
|
-
|
|
1965
2086
|
## unpipe
|
|
1966
2087
|
License: MIT
|
|
1967
2088
|
By: Douglas Christopher Wilson
|
package/dist/client/client.mjs
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import "@vite/env";
|
|
2
|
-
|
|
3
|
-
//#region \0@oxc-project+runtime@0.110.0/helpers/typeof.js
|
|
2
|
+
//#region \0@oxc-project+runtime@0.120.0/helpers/typeof.js
|
|
4
3
|
function _typeof(o) {
|
|
5
4
|
"@babel/helpers - typeof";
|
|
6
5
|
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) {
|
|
@@ -9,9 +8,8 @@ function _typeof(o) {
|
|
|
9
8
|
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
|
10
9
|
}, _typeof(o);
|
|
11
10
|
}
|
|
12
|
-
|
|
13
11
|
//#endregion
|
|
14
|
-
//#region \0@oxc-project+runtime@0.
|
|
12
|
+
//#region \0@oxc-project+runtime@0.120.0/helpers/toPrimitive.js
|
|
15
13
|
function toPrimitive(t, r) {
|
|
16
14
|
if ("object" != _typeof(t) || !t) return t;
|
|
17
15
|
var e = t[Symbol.toPrimitive];
|
|
@@ -22,16 +20,14 @@ function toPrimitive(t, r) {
|
|
|
22
20
|
}
|
|
23
21
|
return ("string" === r ? String : Number)(t);
|
|
24
22
|
}
|
|
25
|
-
|
|
26
23
|
//#endregion
|
|
27
|
-
//#region \0@oxc-project+runtime@0.
|
|
24
|
+
//#region \0@oxc-project+runtime@0.120.0/helpers/toPropertyKey.js
|
|
28
25
|
function toPropertyKey(t) {
|
|
29
26
|
var i = toPrimitive(t, "string");
|
|
30
27
|
return "symbol" == _typeof(i) ? i : i + "";
|
|
31
28
|
}
|
|
32
|
-
|
|
33
29
|
//#endregion
|
|
34
|
-
//#region \0@oxc-project+runtime@0.
|
|
30
|
+
//#region \0@oxc-project+runtime@0.120.0/helpers/defineProperty.js
|
|
35
31
|
function _defineProperty(e, r, t) {
|
|
36
32
|
return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
37
33
|
value: t,
|
|
@@ -40,7 +36,6 @@ function _defineProperty(e, r, t) {
|
|
|
40
36
|
writable: !0
|
|
41
37
|
}) : e[r] = t, e;
|
|
42
38
|
}
|
|
43
|
-
|
|
44
39
|
//#endregion
|
|
45
40
|
//#region src/shared/hmr.ts
|
|
46
41
|
var HMRContext = class {
|
|
@@ -224,9 +219,8 @@ var HMRClient = class {
|
|
|
224
219
|
};
|
|
225
220
|
}
|
|
226
221
|
};
|
|
227
|
-
|
|
228
222
|
//#endregion
|
|
229
|
-
//#region ../../node_modules/.pnpm/nanoid@5.1.
|
|
223
|
+
//#region ../../node_modules/.pnpm/nanoid@5.1.7/node_modules/nanoid/non-secure/index.js
|
|
230
224
|
let urlAlphabet = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
|
|
231
225
|
let nanoid = (size = 21) => {
|
|
232
226
|
let id = "";
|
|
@@ -234,16 +228,12 @@ let nanoid = (size = 21) => {
|
|
|
234
228
|
while (i--) id += urlAlphabet[Math.random() * 64 | 0];
|
|
235
229
|
return id;
|
|
236
230
|
};
|
|
237
|
-
|
|
238
231
|
//#endregion
|
|
239
232
|
//#region src/shared/constants.ts
|
|
240
233
|
let SOURCEMAPPING_URL = "sourceMa";
|
|
241
234
|
SOURCEMAPPING_URL += "ppingURL";
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
//#region src/shared/utils.ts
|
|
245
|
-
const isWindows = typeof process !== "undefined" && process.platform === "win32";
|
|
246
|
-
const AsyncFunction = async function() {}.constructor;
|
|
235
|
+
typeof process !== "undefined" && process.platform;
|
|
236
|
+
(async function() {}).constructor;
|
|
247
237
|
function promiseWithResolvers() {
|
|
248
238
|
let resolve;
|
|
249
239
|
let reject;
|
|
@@ -256,7 +246,6 @@ function promiseWithResolvers() {
|
|
|
256
246
|
reject
|
|
257
247
|
};
|
|
258
248
|
}
|
|
259
|
-
|
|
260
249
|
//#endregion
|
|
261
250
|
//#region src/shared/moduleRunnerTransport.ts
|
|
262
251
|
function reviveInvokeError(e) {
|
|
@@ -450,7 +439,6 @@ const createWebSocketModuleRunnerTransport = (options) => {
|
|
|
450
439
|
}
|
|
451
440
|
};
|
|
452
441
|
};
|
|
453
|
-
|
|
454
442
|
//#endregion
|
|
455
443
|
//#region src/shared/hmrHandler.ts
|
|
456
444
|
function createHMRHandler(handler) {
|
|
@@ -484,7 +472,116 @@ var Queue = class {
|
|
|
484
472
|
return true;
|
|
485
473
|
}
|
|
486
474
|
};
|
|
487
|
-
|
|
475
|
+
//#endregion
|
|
476
|
+
//#region src/shared/forwardConsole.ts
|
|
477
|
+
function setupForwardConsoleHandler(transport, options) {
|
|
478
|
+
if (!options.enabled) return;
|
|
479
|
+
function sendError(type, error) {
|
|
480
|
+
transport.send({
|
|
481
|
+
type: "custom",
|
|
482
|
+
event: "vite:forward-console",
|
|
483
|
+
data: {
|
|
484
|
+
type,
|
|
485
|
+
data: {
|
|
486
|
+
name: error?.name || "Unknown Error",
|
|
487
|
+
message: error?.message || String(error),
|
|
488
|
+
stack: error?.stack
|
|
489
|
+
}
|
|
490
|
+
}
|
|
491
|
+
});
|
|
492
|
+
}
|
|
493
|
+
function sendLog(level, args) {
|
|
494
|
+
transport.send({
|
|
495
|
+
type: "custom",
|
|
496
|
+
event: "vite:forward-console",
|
|
497
|
+
data: {
|
|
498
|
+
type: "log",
|
|
499
|
+
data: {
|
|
500
|
+
level,
|
|
501
|
+
message: formatConsoleArgs(args)
|
|
502
|
+
}
|
|
503
|
+
}
|
|
504
|
+
});
|
|
505
|
+
}
|
|
506
|
+
for (const level of options.logLevels) {
|
|
507
|
+
const original = console[level];
|
|
508
|
+
if (typeof original !== "function") continue;
|
|
509
|
+
console[level] = (...args) => {
|
|
510
|
+
original(...args);
|
|
511
|
+
sendLog(level, args);
|
|
512
|
+
};
|
|
513
|
+
}
|
|
514
|
+
if (options.unhandledErrors && typeof window !== "undefined") {
|
|
515
|
+
window.addEventListener("error", (event) => {
|
|
516
|
+
sendError("error", event.error ?? (event.message ? new Error(event.message) : event));
|
|
517
|
+
});
|
|
518
|
+
window.addEventListener("unhandledrejection", (event) => {
|
|
519
|
+
sendError("unhandled-rejection", event.reason);
|
|
520
|
+
});
|
|
521
|
+
}
|
|
522
|
+
}
|
|
523
|
+
function formatConsoleArgs(args) {
|
|
524
|
+
if (args.length === 0) return "";
|
|
525
|
+
if (typeof args[0] !== "string") return args.map((arg) => stringifyConsoleArg(arg)).join(" ");
|
|
526
|
+
const len = args.length;
|
|
527
|
+
let i = 1;
|
|
528
|
+
let message = args[0].replace(/%[sdjifoOc%]/g, (specifier) => {
|
|
529
|
+
if (specifier === "%%") return "%";
|
|
530
|
+
if (i >= len) return specifier;
|
|
531
|
+
const arg = args[i++];
|
|
532
|
+
switch (specifier) {
|
|
533
|
+
case "%s":
|
|
534
|
+
if (typeof arg === "bigint") return `${arg.toString()}n`;
|
|
535
|
+
return typeof arg === "object" && arg != null ? stringifyConsoleArg(arg) : String(arg);
|
|
536
|
+
case "%d":
|
|
537
|
+
if (typeof arg === "bigint") return `${arg.toString()}n`;
|
|
538
|
+
if (typeof arg === "symbol") return "NaN";
|
|
539
|
+
return Number(arg).toString();
|
|
540
|
+
case "%i":
|
|
541
|
+
if (typeof arg === "bigint") return `${arg.toString()}n`;
|
|
542
|
+
return Number.parseInt(String(arg), 10).toString();
|
|
543
|
+
case "%f": return Number.parseFloat(String(arg)).toString();
|
|
544
|
+
case "%o":
|
|
545
|
+
case "%O": return stringifyConsoleArg(arg);
|
|
546
|
+
case "%j": try {
|
|
547
|
+
return JSON.stringify(arg) ?? "undefined";
|
|
548
|
+
} catch {
|
|
549
|
+
return "[Circular]";
|
|
550
|
+
}
|
|
551
|
+
case "%c": return "";
|
|
552
|
+
default: return specifier;
|
|
553
|
+
}
|
|
554
|
+
});
|
|
555
|
+
for (let arg = args[i]; i < len; arg = args[++i]) if (arg == null || typeof arg !== "object") message += ` ${typeof arg === "symbol" ? arg.toString() : String(arg)}`;
|
|
556
|
+
else message += ` ${stringifyConsoleArg(arg)}`;
|
|
557
|
+
return message;
|
|
558
|
+
}
|
|
559
|
+
function stringifyConsoleArg(value) {
|
|
560
|
+
if (typeof value === "string") return value;
|
|
561
|
+
if (typeof value === "number" || typeof value === "boolean" || typeof value === "undefined") return String(value);
|
|
562
|
+
if (typeof value === "symbol") return value.toString();
|
|
563
|
+
if (typeof value === "function") return value.name ? `[Function: ${value.name}]` : "[Function]";
|
|
564
|
+
if (value instanceof Error) return value.stack || `${value.name}: ${value.message}`;
|
|
565
|
+
if (typeof value === "bigint") return `${value}n`;
|
|
566
|
+
const seen = /* @__PURE__ */ new WeakSet();
|
|
567
|
+
try {
|
|
568
|
+
return JSON.stringify(value, (_, nested) => {
|
|
569
|
+
if (typeof nested === "bigint") return `${nested}n`;
|
|
570
|
+
if (nested instanceof Error) return {
|
|
571
|
+
name: nested.name,
|
|
572
|
+
message: nested.message,
|
|
573
|
+
stack: nested.stack
|
|
574
|
+
};
|
|
575
|
+
if (nested && typeof nested === "object") {
|
|
576
|
+
if (seen.has(nested)) return "[Circular]";
|
|
577
|
+
seen.add(nested);
|
|
578
|
+
}
|
|
579
|
+
return nested;
|
|
580
|
+
}) ?? String(value);
|
|
581
|
+
} catch {
|
|
582
|
+
return String(value);
|
|
583
|
+
}
|
|
584
|
+
}
|
|
488
585
|
//#endregion
|
|
489
586
|
//#region src/client/overlay.ts
|
|
490
587
|
const hmrConfigName = __HMR_CONFIG_NAME__;
|
|
@@ -724,8 +821,7 @@ var ErrorOverlay = class extends HTMLElement {
|
|
|
724
821
|
};
|
|
725
822
|
const overlayId = "vite-error-overlay";
|
|
726
823
|
const { customElements } = globalThis;
|
|
727
|
-
if (customElements && !customElements.get(
|
|
728
|
-
|
|
824
|
+
if (customElements && !customElements.get("vite-error-overlay")) customElements.define(overlayId, ErrorOverlay);
|
|
729
825
|
//#endregion
|
|
730
826
|
//#region src/client/client.ts
|
|
731
827
|
console.debug("[vite] connecting...");
|
|
@@ -739,6 +835,7 @@ const base = __BASE__ || "/";
|
|
|
739
835
|
const hmrTimeout = __HMR_TIMEOUT__;
|
|
740
836
|
const wsToken = __WS_TOKEN__;
|
|
741
837
|
const isBundleMode = __BUNDLED_DEV__;
|
|
838
|
+
const forwardConsole = __SERVER_FORWARD_CONSOLE__;
|
|
742
839
|
const transport = normalizeModuleRunnerTransport((() => {
|
|
743
840
|
let wsTransport = createWebSocketModuleRunnerTransport({
|
|
744
841
|
createConnection: () => new WebSocket(`${socketProtocol}://${socketHost}?token=${wsToken}`, "vite-hmr"),
|
|
@@ -827,6 +924,7 @@ const hmrClient = new HMRClient({
|
|
|
827
924
|
return await importPromise;
|
|
828
925
|
});
|
|
829
926
|
transport.connect(createHMRHandler(handleMessage));
|
|
927
|
+
setupForwardConsoleHandler(transport, forwardConsole);
|
|
830
928
|
async function handleMessage(payload) {
|
|
831
929
|
switch (payload.type) {
|
|
832
930
|
case "connected":
|
|
@@ -1133,6 +1231,5 @@ if (isBundleMode && typeof DevRuntime !== "undefined") {
|
|
|
1133
1231
|
}
|
|
1134
1232
|
} }));
|
|
1135
1233
|
}
|
|
1136
|
-
|
|
1137
1234
|
//#endregion
|
|
1138
|
-
export { ErrorOverlay, createHotContext, injectQuery, removeStyle, updateStyle };
|
|
1235
|
+
export { ErrorOverlay, createHotContext, injectQuery, removeStyle, updateStyle };
|
package/dist/client/env.mjs
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
1
|
import "./logger.js";
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
export { createBuilder, resolveBuildPlugins };
|
|
2
|
+
import { M as createBuilder, z as resolveBuildPlugins } from "./node.js";
|
|
3
|
+
export { createBuilder, resolveBuildPlugins };
|