@vixt/core 0.8.1 → 0.10.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/dist/cli/index.mjs +1 -3
- package/dist/client/index.js +1 -3
- package/dist/node/index.d.mts +2 -2
- package/dist/node/index.mjs +3 -22
- package/package.json +13 -13
package/dist/cli/index.mjs
CHANGED
package/dist/client/index.js
CHANGED
|
@@ -13,7 +13,6 @@ function createVixtApp(options) {
|
|
|
13
13
|
globalThis.useVixtApp = () => vixtApp;
|
|
14
14
|
return vixtApp;
|
|
15
15
|
}
|
|
16
|
-
|
|
17
16
|
//#endregion
|
|
18
17
|
//#region src/client/plugin.ts
|
|
19
18
|
function defineVixtPlugin(definition) {
|
|
@@ -25,6 +24,5 @@ function defineVixtPlugin(definition) {
|
|
|
25
24
|
function applyPlugins(vixt, plugins) {
|
|
26
25
|
for (const plugin of plugins) typeof plugin === "function" && plugin(vixt);
|
|
27
26
|
}
|
|
28
|
-
|
|
29
27
|
//#endregion
|
|
30
|
-
export { applyPlugins, createVixtApp, defineAppConfig, defineVixtPlugin, useAppConfig, useVixtApp };
|
|
28
|
+
export { applyPlugins, createVixtApp, defineAppConfig, defineVixtPlugin, useAppConfig, useVixtApp };
|
package/dist/node/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ConfigLayer, ConfigLayerMeta, LoadConfigOptions, ResolvedConfig } from "c12";
|
|
2
|
-
import * as
|
|
2
|
+
import * as _$vite from "vite";
|
|
3
3
|
import { HtmlTagDescriptor, InlineConfig, LogLevel, PluginOption, ServerOptions, UserConfig } from "vite";
|
|
4
4
|
import Legacy from "@vitejs/plugin-legacy";
|
|
5
5
|
import Analyzer from "vite-bundle-analyzer";
|
|
@@ -15,7 +15,7 @@ interface Vixt {
|
|
|
15
15
|
_modules: VixtModule[];
|
|
16
16
|
}
|
|
17
17
|
declare function loadVixt(opts?: LoadConfigOptions<VixtOptions>): Promise<Vixt>;
|
|
18
|
-
declare function createVixtPlugin(loadOptions: LoadConfigOptions<VixtOptions>): (options?: VixtOptions | undefined) =>
|
|
18
|
+
declare function createVixtPlugin(loadOptions: LoadConfigOptions<VixtOptions>): (options?: VixtOptions | undefined) => _$vite.PluginOption;
|
|
19
19
|
//#endregion
|
|
20
20
|
//#region src/node/module.d.ts
|
|
21
21
|
type ExtractPluginOptions<Options = any> = (Options extends ((...args: any[]) => any) ? Parameters<Options>[0] : Options);
|
package/dist/node/index.mjs
CHANGED
|
@@ -13,7 +13,6 @@ import Analyzer from "vite-bundle-analyzer";
|
|
|
13
13
|
import Ssl from "@vitejs/plugin-basic-ssl";
|
|
14
14
|
import Checker from "vite-plugin-checker";
|
|
15
15
|
import { builders, parseExpression, parseModule } from "magicast";
|
|
16
|
-
|
|
17
16
|
//#region src/node/env.ts
|
|
18
17
|
function loadCLIOptions() {
|
|
19
18
|
return cac().parse().options ?? {};
|
|
@@ -49,7 +48,6 @@ function loadWorkspaceEnv(mode, prefixes) {
|
|
|
49
48
|
const workspaceDir = findUpWorkspaceDir();
|
|
50
49
|
return workspaceDir ? loadEnv$1(mode, workspaceDir, prefixes) : {};
|
|
51
50
|
}
|
|
52
|
-
|
|
53
51
|
//#endregion
|
|
54
52
|
//#region src/node/config.ts
|
|
55
53
|
function defineVixtConfig(input) {
|
|
@@ -131,7 +129,6 @@ const VixtClientAutoImports = { "@vixt/core/client": [
|
|
|
131
129
|
"useAppConfig",
|
|
132
130
|
"useVixtApp"
|
|
133
131
|
] };
|
|
134
|
-
|
|
135
132
|
//#endregion
|
|
136
133
|
//#region src/node/module.ts
|
|
137
134
|
function defineVitePlugin(pluginFn) {
|
|
@@ -171,7 +168,6 @@ async function applyLayerModules({ config, layers = [] }) {
|
|
|
171
168
|
}
|
|
172
169
|
return modules;
|
|
173
170
|
}
|
|
174
|
-
|
|
175
171
|
//#endregion
|
|
176
172
|
//#region src/node/modules/alias.ts
|
|
177
173
|
const name$8 = "vixt:alias";
|
|
@@ -202,7 +198,6 @@ var alias_default = defineVixtModule({
|
|
|
202
198
|
};
|
|
203
199
|
}
|
|
204
200
|
});
|
|
205
|
-
|
|
206
201
|
//#endregion
|
|
207
202
|
//#region src/node/modules/app.ts
|
|
208
203
|
function resolveHead(tag, attrs) {
|
|
@@ -297,13 +292,9 @@ var app_default = defineVixtModule({
|
|
|
297
292
|
};
|
|
298
293
|
}
|
|
299
294
|
});
|
|
300
|
-
|
|
301
|
-
//#endregion
|
|
302
|
-
//#region src/node/modules/build.ts
|
|
303
|
-
const name$6 = "vixt:build";
|
|
304
295
|
var build_default = defineVixtModule({
|
|
305
296
|
meta: {
|
|
306
|
-
name:
|
|
297
|
+
name: "vixt:build",
|
|
307
298
|
configKey: "build"
|
|
308
299
|
},
|
|
309
300
|
setup(options) {
|
|
@@ -318,7 +309,6 @@ var build_default = defineVixtModule({
|
|
|
318
309
|
return [analyzeOptions.enabled && Analyzer(analyzeOptions), legacyOptions.enabled && Legacy(legacyOptions)];
|
|
319
310
|
}
|
|
320
311
|
});
|
|
321
|
-
|
|
322
312
|
//#endregion
|
|
323
313
|
//#region src/node/modules/dev-server.ts
|
|
324
314
|
const name$5 = "vixt:dev-server";
|
|
@@ -376,7 +366,6 @@ var dev_server_default = defineVixtModule({
|
|
|
376
366
|
}, sslOptions.enabled && Ssl(sslOptions)];
|
|
377
367
|
}
|
|
378
368
|
});
|
|
379
|
-
|
|
380
369
|
//#endregion
|
|
381
370
|
//#region src/node/modules/typescript.ts
|
|
382
371
|
function generateTsConfig(options, vixt) {
|
|
@@ -430,7 +419,7 @@ var typescript_default = defineVixtModule({
|
|
|
430
419
|
configKey: "typescript"
|
|
431
420
|
},
|
|
432
421
|
defaults(vixt) {
|
|
433
|
-
const {
|
|
422
|
+
const { alias } = vixt.options;
|
|
434
423
|
const paths = {};
|
|
435
424
|
for (const [ak, av] of Object.entries(alias ?? {})) {
|
|
436
425
|
const stats = fs.existsSync(av) ? fs.statSync(av) : null;
|
|
@@ -442,7 +431,6 @@ var typescript_default = defineVixtModule({
|
|
|
442
431
|
tsConfig: {
|
|
443
432
|
extends: "@vue/tsconfig/tsconfig.dom.json",
|
|
444
433
|
compilerOptions: {
|
|
445
|
-
baseUrl: rootDir,
|
|
446
434
|
paths,
|
|
447
435
|
types: ["vite/client"]
|
|
448
436
|
},
|
|
@@ -466,7 +454,6 @@ var typescript_default = defineVixtModule({
|
|
|
466
454
|
}, Checker(options.typeCheck ?? {})];
|
|
467
455
|
}
|
|
468
456
|
});
|
|
469
|
-
|
|
470
457
|
//#endregion
|
|
471
458
|
//#region src/node/modules/virtual-app-config.ts
|
|
472
459
|
const name$3 = "virtual:vixt:app-config";
|
|
@@ -508,7 +495,6 @@ var virtual_app_config_default = defineVixtModule({
|
|
|
508
495
|
};
|
|
509
496
|
}
|
|
510
497
|
});
|
|
511
|
-
|
|
512
498
|
//#endregion
|
|
513
499
|
//#region src/node/modules/virtual-css.ts
|
|
514
500
|
const name$2 = "virtual:vixt:css";
|
|
@@ -528,7 +514,6 @@ var virtual_css_default = defineVixtModule({
|
|
|
528
514
|
};
|
|
529
515
|
}
|
|
530
516
|
});
|
|
531
|
-
|
|
532
517
|
//#endregion
|
|
533
518
|
//#region src/node/modules/virtual-plugins.ts
|
|
534
519
|
const name$1 = "virtual:vixt:plugins";
|
|
@@ -568,7 +553,6 @@ var virtual_plugins_default = defineVixtModule({
|
|
|
568
553
|
};
|
|
569
554
|
}
|
|
570
555
|
});
|
|
571
|
-
|
|
572
556
|
//#endregion
|
|
573
557
|
//#region src/node/modules/vite.ts
|
|
574
558
|
const name = "vixt:vite";
|
|
@@ -602,7 +586,6 @@ var vite_default = defineVixtModule({
|
|
|
602
586
|
};
|
|
603
587
|
}
|
|
604
588
|
});
|
|
605
|
-
|
|
606
589
|
//#endregion
|
|
607
590
|
//#region src/node/modules/index.ts
|
|
608
591
|
const virtualModuleIds = {
|
|
@@ -621,7 +604,6 @@ const builtinModules = [
|
|
|
621
604
|
virtual_css_default,
|
|
622
605
|
virtual_plugins_default
|
|
623
606
|
];
|
|
624
|
-
|
|
625
607
|
//#endregion
|
|
626
608
|
//#region src/node/vixt.ts
|
|
627
609
|
async function loadVixt(opts) {
|
|
@@ -648,6 +630,5 @@ function createVixtPlugin(loadOptions) {
|
|
|
648
630
|
return vixt._modules.map((module) => installModule(module, {}, vixt));
|
|
649
631
|
});
|
|
650
632
|
}
|
|
651
|
-
|
|
652
633
|
//#endregion
|
|
653
|
-
export { VixtClientAutoImports, applyLayerModules, applyLayers, builtinModules, createVixtPlugin, defineVitePlugin, defineVixtConfig, defineVixtModule, findUpWorkspaceDir, installModule, isSamePath, loadCLIOptions, loadEnv, loadMode, loadVixt, loadVixtConfig, loadWorkspaceEnv, resolveLayersDirs, virtualModuleIds };
|
|
634
|
+
export { VixtClientAutoImports, applyLayerModules, applyLayers, builtinModules, createVixtPlugin, defineVitePlugin, defineVixtConfig, defineVixtModule, findUpWorkspaceDir, installModule, isSamePath, loadCLIOptions, loadEnv, loadMode, loadVixt, loadVixtConfig, loadWorkspaceEnv, resolveLayersDirs, virtualModuleIds };
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vixt/core",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.10.1",
|
|
5
5
|
"author": "SoulLyoko<https://github.com/SoulLyoko>",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"homepage": "https://soullyoko.github.io/vixt/",
|
|
@@ -29,22 +29,22 @@
|
|
|
29
29
|
],
|
|
30
30
|
"dependencies": {
|
|
31
31
|
"@types/fs-extra": "^11.0.4",
|
|
32
|
-
"@vitejs/plugin-basic-ssl": "^2.
|
|
33
|
-
"@vitejs/plugin-legacy": "^8.0.
|
|
34
|
-
"@vue/tsconfig": "^0.
|
|
35
|
-
"c12": "^3.3.
|
|
36
|
-
"cac": "^
|
|
37
|
-
"citty": "^0.2.
|
|
38
|
-
"defu": "^6.1.
|
|
32
|
+
"@vitejs/plugin-basic-ssl": "^2.3.0",
|
|
33
|
+
"@vitejs/plugin-legacy": "^8.0.1",
|
|
34
|
+
"@vue/tsconfig": "^0.9.1",
|
|
35
|
+
"c12": "^3.3.4",
|
|
36
|
+
"cac": "^7.0.0",
|
|
37
|
+
"citty": "^0.2.2",
|
|
38
|
+
"defu": "^6.1.7",
|
|
39
39
|
"find-up": "^8.0.0",
|
|
40
|
-
"fs-extra": "^11.3.
|
|
40
|
+
"fs-extra": "^11.3.4",
|
|
41
41
|
"jiti": "^2.6.1",
|
|
42
|
-
"magicast": "^0.5.
|
|
43
|
-
"mlly": "^1.8.
|
|
42
|
+
"magicast": "^0.5.2",
|
|
43
|
+
"mlly": "^1.8.2",
|
|
44
44
|
"pathe": "^2.0.3",
|
|
45
45
|
"pkg-types": "^2.3.0",
|
|
46
|
-
"vite": "^
|
|
47
|
-
"vite-bundle-analyzer": "^1.3.
|
|
46
|
+
"vite": "^8.0.7",
|
|
47
|
+
"vite-bundle-analyzer": "^1.3.7",
|
|
48
48
|
"vite-plugin-checker": "^0.12.0"
|
|
49
49
|
}
|
|
50
50
|
}
|