@zeus-js/bundler-plugin 0.1.0-beta.1 → 0.1.0-beta.2

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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * bundler-plugin v0.1.0-beta.1
2
+ * bundler-plugin v0.1.0-beta.2
3
3
  * (c) 2026 baicie
4
4
  * Released under the MIT License.
5
5
  **/
@@ -33,6 +33,8 @@ let node_module = require("node:module");
33
33
  let node_path = require("node:path");
34
34
  node_path = __toESM(node_path, 1);
35
35
  let vite = require("vite");
36
+ let node_fs = require("node:fs");
37
+ node_fs = __toESM(node_fs, 1);
36
38
  let _zeus_js_component_analyzer = require("@zeus-js/component-analyzer");
37
39
  let fast_glob = require("fast-glob");
38
40
  fast_glob = __toESM(fast_glob, 1);
@@ -41,12 +43,17 @@ picomatch = __toESM(picomatch, 1);
41
43
  let node_fs_promises = require("node:fs/promises");
42
44
  node_fs_promises = __toESM(node_fs_promises, 1);
43
45
  let _babel_core = require("@babel/core");
46
+ let _babel_preset_typescript = require("@babel/preset-typescript");
47
+ _babel_preset_typescript = __toESM(_babel_preset_typescript, 1);
44
48
  let _zeus_js_compiler = require("@zeus-js/compiler");
45
49
  _zeus_js_compiler = __toESM(_zeus_js_compiler, 1);
46
50
  //#region packages/web-c/bundler-plugin/src/filter.ts
47
51
  function cleanUrl(id) {
48
52
  return id.replace(/[?#].*$/, "");
49
53
  }
54
+ function isTypeScriptLike(id) {
55
+ return /\.[cm]?tsx?$/.test(cleanUrl(id));
56
+ }
50
57
  //#endregion
51
58
  //#region packages/web-c/bundler-plugin/src/componentTransformFilter.ts
52
59
  function normalizePath$1(value) {
@@ -75,12 +82,28 @@ const DEFAULT_COMPONENT_EXCLUDE = [
75
82
  "node_modules/**",
76
83
  "dist/**"
77
84
  ];
85
+ const DEFAULT_TRANSFORM_INCLUDE = DEFAULT_COMPONENT_INCLUDE;
86
+ const DEFAULT_TRANSFORM_EXCLUDE = [
87
+ "**/*.test.*",
88
+ "**/*.spec.*",
89
+ "**/__tests__/**",
90
+ "**/*.d.ts",
91
+ "node_modules/**",
92
+ "dist/**"
93
+ ];
78
94
  function resolveComponentInclude(include) {
79
95
  return (include === null || include === void 0 ? void 0 : include.length) ? include : DEFAULT_COMPONENT_INCLUDE;
80
96
  }
81
97
  function resolveComponentExclude(exclude) {
82
98
  return (exclude === null || exclude === void 0 ? void 0 : exclude.length) ? exclude : DEFAULT_COMPONENT_EXCLUDE;
83
99
  }
100
+ function resolveTransformInclude(include, componentInclude) {
101
+ if (include === null || include === void 0 ? void 0 : include.length) return include;
102
+ return Array.from(new Set([...DEFAULT_TRANSFORM_INCLUDE, ...componentInclude]));
103
+ }
104
+ function resolveTransformExclude(exclude) {
105
+ return (exclude === null || exclude === void 0 ? void 0 : exclude.length) ? exclude : DEFAULT_TRANSFORM_EXCLUDE;
106
+ }
84
107
  //#endregion
85
108
  //#region packages/web-c/bundler-plugin/src/diagnostics.ts
86
109
  function formatDiagnostic(diagnostic) {
@@ -220,18 +243,29 @@ function normalizeTagName(tag, stripPrefix) {
220
243
  //#endregion
221
244
  //#region packages/web-c/bundler-plugin/src/transform.ts
222
245
  async function transformZeus(options) {
223
- var _compiler$moduleName;
224
- const { id, code, compiler, sourcemap = true } = options;
246
+ var _compilerOptions$modu;
247
+ const { id, code, compiler, sourcemap = true, transpile = false } = options;
248
+ const isTs = isTypeScriptLike(id);
249
+ const isTsx = /\.[cm]?tsx$/.test(id.replace(/[?#].*$/, ""));
250
+ const shouldRunCompiler = compiler !== false;
251
+ const shouldStripTs = transpile && isTs;
252
+ if (!shouldRunCompiler && !shouldStripTs) return null;
253
+ const compilerOptions = compiler === false ? {} : compiler === void 0 ? {} : compiler;
225
254
  const result = await (0, _babel_core.transformAsync)(code, {
226
255
  filename: id,
227
256
  sourceMaps: sourcemap,
228
- plugins: [[_zeus_js_compiler.default, {
229
- moduleName: (_compiler$moduleName = compiler === null || compiler === void 0 ? void 0 : compiler.moduleName) !== null && _compiler$moduleName !== void 0 ? _compiler$moduleName : "@zeus-js/runtime-dom",
257
+ plugins: shouldRunCompiler ? [[_zeus_js_compiler.default, {
258
+ moduleName: (_compilerOptions$modu = compilerOptions.moduleName) !== null && _compilerOptions$modu !== void 0 ? _compilerOptions$modu : "@zeus-js/runtime-dom",
230
259
  generate: "dom",
231
260
  hydratable: false,
232
261
  delegateEvents: true,
233
- ...compiler
234
- }]],
262
+ ...compilerOptions
263
+ }]] : [],
264
+ presets: shouldStripTs ? [[_babel_preset_typescript.default, {
265
+ allExtensions: true,
266
+ isTSX: isTsx,
267
+ allowDeclareFields: true
268
+ }]] : [],
235
269
  parserOpts: {
236
270
  sourceType: "module",
237
271
  plugins: ["typescript", "jsx"]
@@ -330,32 +364,36 @@ function normalizePath(value) {
330
364
  return value.replace(/\\/g, "/").replace(/^\.\//, "");
331
365
  }
332
366
  //#endregion
333
- //#region packages/web-c/bundler-plugin/src/rollup.ts
334
- function createZeusPlugin(options = {}) {
335
- let shouldTransform = (_id) => false;
336
- const virtualModules = new VirtualModuleRegistry();
367
+ //#region packages/web-c/bundler-plugin/src/core.ts
368
+ function createZeusBundlerPlugin(options = {}, createOptions) {
369
+ const target = createOptions.target;
370
+ let shouldCompileZeus = (_id) => false;
337
371
  let ctx;
372
+ let root = process.cwd();
373
+ const virtualModules = new VirtualModuleRegistry();
338
374
  return {
339
- name: "zeus-bundler-plugin",
375
+ name: resolvePluginName(target),
340
376
  async buildStart() {
341
- var _options$components, _options$components2, _options$plugins;
377
+ var _options$components, _options$components2, _options$transform, _options$transform2, _options$plugins;
342
378
  virtualModules.clear();
343
- const root = resolveRoot(options.root);
344
- const include = resolveComponentInclude((_options$components = options.components) === null || _options$components === void 0 ? void 0 : _options$components.include);
345
- const exclude = resolveComponentExclude((_options$components2 = options.components) === null || _options$components2 === void 0 ? void 0 : _options$components2.exclude);
346
- shouldTransform = createComponentTransformFilter({
379
+ root = resolveRoot(options.root);
380
+ const componentInclude = resolveComponentInclude((_options$components = options.components) === null || _options$components === void 0 ? void 0 : _options$components.include);
381
+ const componentExclude = resolveComponentExclude((_options$components2 = options.components) === null || _options$components2 === void 0 ? void 0 : _options$components2.exclude);
382
+ const transformInclude = resolveTransformInclude((_options$transform = options.transform) === null || _options$transform === void 0 ? void 0 : _options$transform.include, componentInclude);
383
+ const transformExclude = resolveTransformExclude((_options$transform2 = options.transform) === null || _options$transform2 === void 0 ? void 0 : _options$transform2.exclude);
384
+ shouldCompileZeus = createComponentTransformFilter({
347
385
  root,
348
- include,
349
- exclude
386
+ include: transformInclude,
387
+ exclude: transformExclude
350
388
  });
351
389
  const dts = await resolveDts({
352
390
  root,
353
391
  mode: options.dts,
354
- include,
355
- exclude
392
+ include: componentInclude,
393
+ exclude: componentExclude
356
394
  });
357
- const manifestResult = await createManifest(root, include, exclude);
358
- for (const file of await collectWatchFiles(root, include, exclude)) this.addWatchFile(file);
395
+ const manifestResult = await createManifest(root, componentInclude, componentExclude);
396
+ for (const file of await collectWatchFiles(root, componentInclude, componentExclude)) this.addWatchFile(file);
359
397
  const diagnostics = manifestResult.diagnostics;
360
398
  for (const diagnostic of diagnostics) {
361
399
  const message = formatDiagnostic(diagnostic);
@@ -364,13 +402,12 @@ function createZeusPlugin(options = {}) {
364
402
  }
365
403
  if (hasErrorDiagnostics(diagnostics)) this.error("[zeus] component analyzer failed.");
366
404
  if (options.diagnostics === "verbose") this.warn(`[zeus] dts ${dts.enabled ? "enabled" : "disabled"}: ${dts.reason.join(", ") || "no signal"}`);
367
- const outputs = createOutputRegistry();
368
405
  ctx = {
369
406
  root,
370
407
  manifest: manifestResult.manifest,
371
408
  diagnostics,
372
409
  dts,
373
- outputs,
410
+ outputs: createOutputRegistry(),
374
411
  emitFile: this.emitFile.bind(this),
375
412
  warn: this.warn.bind(this),
376
413
  error: this.error.bind(this),
@@ -395,26 +432,31 @@ function createZeusPlugin(options = {}) {
395
432
  }
396
433
  },
397
434
  resolveId(id, importer) {
398
- const resolved = virtualModules.resolve(id, importer);
399
- if (resolved) return {
400
- id: resolved,
435
+ const resolvedVirtual = virtualModules.resolve(id, importer);
436
+ if (resolvedVirtual) return {
437
+ id: resolvedVirtual,
401
438
  moduleSideEffects: "no-treeshake"
402
439
  };
440
+ if (target === "rollup") {
441
+ const resolvedTs = resolveTsLikeImport(id, importer, { extensions: options.resolveExtensions });
442
+ if (resolvedTs) return resolvedTs;
443
+ }
403
444
  return null;
404
445
  },
405
446
  load(id) {
406
447
  return virtualModules.load(id);
407
448
  },
408
449
  async transform(code, id) {
409
- if (!shouldTransform(id)) return null;
410
- const result = await transformZeus({
450
+ const shouldRunZeus = shouldCompileZeus(id);
451
+ const shouldStripTs = resolveTranspile(options.transpile, target) && isTypeScriptLike(id);
452
+ if (!shouldRunZeus && !shouldStripTs) return null;
453
+ return await transformZeus({
411
454
  id,
412
455
  code,
413
- compiler: options.compiler,
414
- sourcemap: true
456
+ compiler: shouldRunZeus ? options.compiler : false,
457
+ sourcemap: true,
458
+ transpile: shouldStripTs
415
459
  });
416
- if (!result) return null;
417
- return result;
418
460
  },
419
461
  async generateBundle(_, bundle) {
420
462
  var _options$plugins2;
@@ -429,6 +471,19 @@ function createZeusPlugin(options = {}) {
429
471
  }
430
472
  };
431
473
  }
474
+ function resolvePluginName(target) {
475
+ if (target === "vite") return "vite-plugin-zeus";
476
+ if (target === "rolldown") return "rolldown-plugin-zeus";
477
+ return "rollup-plugin-zeus";
478
+ }
479
+ function resolveTranspile(value, target) {
480
+ if (typeof value === "boolean") return value;
481
+ return target === "rollup";
482
+ }
483
+ function resolveRoot(root) {
484
+ if (typeof root === "function") return node_path.default.resolve(root());
485
+ return node_path.default.resolve(root !== null && root !== void 0 ? root : process.cwd());
486
+ }
432
487
  async function createManifest(root, include, exclude) {
433
488
  if (!include.length) return {
434
489
  manifest: {
@@ -451,9 +506,37 @@ async function collectWatchFiles(root, include, exclude) {
451
506
  ignore: exclude
452
507
  });
453
508
  }
454
- function resolveRoot(root) {
455
- if (typeof root === "function") return node_path.default.resolve(root());
456
- return node_path.default.resolve(root !== null && root !== void 0 ? root : process.cwd());
509
+ function resolveTsLikeImport(id, importer, options) {
510
+ var _options$extensions;
511
+ if (!importer) return null;
512
+ if (cleanUrl(id) !== id) return null;
513
+ const source = cleanUrl(id);
514
+ const from = cleanUrl(importer);
515
+ if (source.startsWith("\0") || from.startsWith("\0")) return null;
516
+ if (!source.startsWith(".") && !isAbsoluteImportPath(source)) return null;
517
+ if (node_path.default.extname(source)) return null;
518
+ if (options.extensions === false) return null;
519
+ const extensions = (_options$extensions = options.extensions) !== null && _options$extensions !== void 0 ? _options$extensions : [
520
+ ".ts",
521
+ ".tsx",
522
+ ".mts",
523
+ ".cts",
524
+ ".js",
525
+ ".jsx",
526
+ ".mjs",
527
+ ".cjs"
528
+ ];
529
+ const base = isAbsoluteImportPath(source) ? source : node_path.default.resolve(node_path.default.dirname(from), source);
530
+ const candidates = [
531
+ base,
532
+ ...extensions.map((ext) => `${base}${ext}`),
533
+ ...extensions.map((ext) => node_path.default.join(base, `index${ext}`))
534
+ ];
535
+ for (const file of candidates) if (node_fs.default.existsSync(file) && node_fs.default.statSync(file).isFile()) return file;
536
+ return null;
537
+ }
538
+ function isAbsoluteImportPath(id) {
539
+ return node_path.default.isAbsolute(id) || /^[a-zA-Z]:[\\/]/.test(id);
457
540
  }
458
541
  function emitOutputFile(pluginContext, file) {
459
542
  if (file.type === "asset") {
@@ -482,21 +565,41 @@ function emitVirtualEntries(modules, pluginContext) {
482
565
  }
483
566
  }
484
567
  //#endregion
568
+ //#region packages/web-c/bundler-plugin/src/external.ts
569
+ function collectPluginExternals(options) {
570
+ var _options$plugins;
571
+ const set = /* @__PURE__ */ new Set();
572
+ for (const plugin of (_options$plugins = options.plugins) !== null && _options$plugins !== void 0 ? _options$plugins : []) {
573
+ var _plugin$external;
574
+ for (const dep of (_plugin$external = plugin.external) !== null && _plugin$external !== void 0 ? _plugin$external : []) set.add(dep);
575
+ }
576
+ return Array.from(set);
577
+ }
578
+ function mergeExternal(userExternal, pluginExternal) {
579
+ if (!userExternal) return pluginExternal;
580
+ if (typeof userExternal === "function") return (source, importer, isResolved) => {
581
+ return pluginExternal.includes(source) || userExternal(source, importer, isResolved);
582
+ };
583
+ return [...Array.isArray(userExternal) ? userExternal : [userExternal], ...pluginExternal];
584
+ }
585
+ //#endregion
485
586
  //#region packages/web-c/bundler-plugin/src/vite.ts
486
587
  function createZeusVitePlugin(options = {}) {
487
- var _options$root;
588
+ var _options$root, _options$transpile;
488
589
  let resolvedConfig;
489
590
  return {
490
- ...createZeusPlugin({
591
+ ...createZeusBundlerPlugin({
491
592
  ...options,
492
593
  root: (_options$root = options.root) !== null && _options$root !== void 0 ? _options$root : (() => {
493
594
  var _resolvedConfig$root;
494
595
  return (_resolvedConfig$root = resolvedConfig === null || resolvedConfig === void 0 ? void 0 : resolvedConfig.root) !== null && _resolvedConfig$root !== void 0 ? _resolvedConfig$root : process.cwd();
495
- })
496
- }),
596
+ }),
597
+ transpile: (_options$transpile = options.transpile) !== null && _options$transpile !== void 0 ? _options$transpile : false
598
+ }, { target: "vite" }),
497
599
  name: "vite-plugin-zeus",
498
600
  enforce: "pre",
499
601
  async config(userConfig) {
602
+ var _userConfig$build;
500
603
  const runtimeDomEntry = resolveRuntimeDOMEntry(userConfig.root);
501
604
  const pluginExternals = collectPluginExternals(options);
502
605
  const pluginConfig = {
@@ -511,33 +614,14 @@ function createZeusVitePlugin(options = {}) {
511
614
  ]
512
615
  }
513
616
  };
514
- if (pluginExternals.length) {
515
- var _userConfig$build;
516
- return (0, vite.mergeConfig)(pluginConfig, { build: { rollupOptions: { external: mergeExternal((_userConfig$build = userConfig.build) === null || _userConfig$build === void 0 || (_userConfig$build = _userConfig$build.rollupOptions) === null || _userConfig$build === void 0 ? void 0 : _userConfig$build.external, pluginExternals) } } });
517
- }
518
- return pluginConfig;
617
+ if (!pluginExternals.length) return pluginConfig;
618
+ return (0, vite.mergeConfig)(pluginConfig, { build: { rollupOptions: { external: mergeExternal((_userConfig$build = userConfig.build) === null || _userConfig$build === void 0 || (_userConfig$build = _userConfig$build.rollupOptions) === null || _userConfig$build === void 0 ? void 0 : _userConfig$build.external, pluginExternals) } } });
519
619
  },
520
620
  configResolved(config) {
521
621
  resolvedConfig = config;
522
622
  }
523
623
  };
524
624
  }
525
- function collectPluginExternals(options) {
526
- var _options$plugins;
527
- const set = /* @__PURE__ */ new Set();
528
- for (const plugin of (_options$plugins = options.plugins) !== null && _options$plugins !== void 0 ? _options$plugins : []) {
529
- var _plugin$external;
530
- for (const dep of (_plugin$external = plugin.external) !== null && _plugin$external !== void 0 ? _plugin$external : []) set.add(dep);
531
- }
532
- return Array.from(set);
533
- }
534
- function mergeExternal(userExternal, pluginExternal) {
535
- if (!userExternal) return pluginExternal;
536
- if (typeof userExternal === "function") return (source, importer, isResolved) => {
537
- return pluginExternal.includes(source) || userExternal(source, importer, isResolved);
538
- };
539
- return [...Array.isArray(userExternal) ? userExternal : [userExternal], ...pluginExternal];
540
- }
541
625
  async function isRolldownVite() {
542
626
  try {
543
627
  const vite$1 = await import("vite");
@@ -562,4 +646,3 @@ function resolveRuntimeDOMEntry(root) {
562
646
  exports.createZeusVitePlugin = createZeusVitePlugin;
563
647
  exports.default = createZeusVitePlugin;
564
648
  exports.zeus = createZeusVitePlugin;
565
- exports.mergeExternal = mergeExternal;
package/dist/vite.d.ts CHANGED
@@ -1,6 +1,150 @@
1
- import type { RollupExternalOption, ZeusBundlerPluginOptions } from './types';
2
- import type { Plugin } from 'vite';
1
+ import { CompilerOptions } from '@zeus-js/compiler';
2
+ import { ComponentManifest, AnalyzerDiagnostic } from '@zeus-js/component-analyzer';
3
+ import { Plugin } from 'vite';
3
4
 
4
- export default createZeusVitePlugin;
5
- export { createZeusVitePlugin as zeus };
5
+ type MaybePromise<T> = T | Promise<T>;
6
+ type RootOption = string | (() => string);
7
+ type ZeusOutputKind = 'wc' | 'react' | 'vue' | 'icons-react' | 'icons-vue' | 'icons-wc' | 'asset';
8
+ type DtsMode = boolean | 'auto';
9
+ interface ResolvedDts {
10
+ enabled: boolean;
11
+ mode: DtsMode;
12
+ reason: DtsAutoReason[];
13
+ }
14
+ type DtsAutoReason = 'explicit-enabled' | 'explicit-disabled' | 'package-types-field' | 'typescript-dependency' | 'tsconfig' | 'typescript-source';
15
+ interface ZeusBuildContext {
16
+ root: string;
17
+ manifest: ComponentManifest;
18
+ diagnostics: AnalyzerDiagnostic[];
19
+ dts: ResolvedDts;
20
+ outputs: ZeusOutputRegistry;
21
+ emitFile: (file: unknown) => string | void;
22
+ warn: (message: string | Error) => void;
23
+ error: (message: string | Error) => never;
24
+ addWatchFile: (id: string) => void;
25
+ meta: {
26
+ watchMode: boolean;
27
+ };
28
+ }
29
+ type ZeusOutputBundle = Record<string, unknown>;
30
+ interface ZeusOutputRegistry {
31
+ register(kind: ZeusOutputKind, options: ZeusOutputRegistration): void;
32
+ has(kind: ZeusOutputKind): boolean;
33
+ get(kind: ZeusOutputKind): RequiredZeusOutputRegistration;
34
+ getDir(kind: ZeusOutputKind): string;
35
+ getFileName(kind: ZeusOutputKind, tag: string): string;
36
+ join(kind: ZeusOutputKind, fileName: string): string;
37
+ }
38
+ interface ZeusOutputRegistration {
39
+ outDir?: string;
40
+ stripPrefix?: string | false;
41
+ fileName?: (tag: string, kind: ZeusOutputKind) => string;
42
+ }
43
+ interface RequiredZeusOutputRegistration {
44
+ outDir: string;
45
+ stripPrefix: string | false;
46
+ fileName?: (tag: string, kind: ZeusOutputKind) => string;
47
+ }
48
+ interface ZeusVirtualModule {
49
+ id: string;
50
+ code: string;
51
+ fileName?: string;
52
+ }
53
+ interface ZeusOutputAsset {
54
+ type: 'asset';
55
+ fileName: string;
56
+ source: string | Uint8Array;
57
+ }
58
+ interface ZeusOutputChunk {
59
+ type: 'chunk';
60
+ id: string;
61
+ fileName?: string;
62
+ }
63
+ type ZeusOutputFile = ZeusOutputAsset | ZeusOutputChunk;
64
+ interface ZeusComponentPlugin {
65
+ name: string;
66
+ /**
67
+ * Register output dirs / externals / plugin metadata.
68
+ *
69
+ * This hook runs before virtualModules().
70
+ */
71
+ setup?(ctx: ZeusBuildContext): void | Promise<void>;
72
+ buildStart?(ctx: ZeusBuildContext): MaybePromise<void>;
73
+ virtualModules?(ctx: ZeusBuildContext): MaybePromise<ZeusVirtualModule[] | void>;
74
+ generateBundle?(ctx: ZeusBuildContext, bundle: ZeusOutputBundle): MaybePromise<ZeusOutputFile[] | void>;
75
+ /**
76
+ * Framework dependencies that bundler config helpers should externalize.
77
+ *
78
+ * Used by the Vite adapter, defineZeusRollupConfig(), and
79
+ * defineZeusRolldownConfig().
80
+ */
81
+ external?: string[];
82
+ }
83
+ interface ZeusBundlerPluginOptions {
84
+ /**
85
+ * Project root.
86
+ *
87
+ * @default
88
+ * - Vite: resolved config.root
89
+ * - Rollup/Rolldown: process.cwd()
90
+ */
91
+ root?: RootOption;
92
+ /**
93
+ * Component source scan options.
94
+ * See DEFAULT_COMPONENT_INCLUDE and DEFAULT_COMPONENT_EXCLUDE in defaults.ts.
95
+ */
96
+ components?: {
97
+ include?: string[];
98
+ exclude?: string[];
99
+ };
100
+ /**
101
+ * Zeus JSX compile transform filter.
102
+ *
103
+ * This is intentionally separate from `components`: files can be excluded
104
+ * from component analysis / manifest generation while still compiling JSX.
105
+ */
106
+ transform?: {
107
+ include?: string[];
108
+ exclude?: string[];
109
+ };
110
+ /**
111
+ * Declaration generation mode.
112
+ *
113
+ * @default 'auto'
114
+ */
115
+ dts?: DtsMode;
116
+ /**
117
+ * Compiler options.
118
+ */
119
+ compiler?: Partial<CompilerOptions>;
120
+ /**
121
+ * Print analyzer diagnostics.
122
+ *
123
+ * @default true
124
+ */
125
+ diagnostics?: boolean | 'verbose';
126
+ /**
127
+ * Component-host plugins.
128
+ */
129
+ plugins?: ZeusComponentPlugin[];
130
+ /**
131
+ * Enable TypeScript transpilation via Babel preset-typescript.
132
+ *
133
+ * @default
134
+ * - rollup: true
135
+ * - rolldown: false
136
+ * - vite: false
137
+ */
138
+ transpile?: boolean;
139
+ /**
140
+ * Rollup adapter only. Additional extensions to try when resolving imports.
141
+ * Set to `false` to disable extension resolution.
142
+ *
143
+ * @default ['.ts', '.tsx', '.mts', '.cts', '.js', '.jsx', '.mjs', '.cjs']
144
+ */
145
+ resolveExtensions?: string[] | false;
146
+ }
6
147
 
148
+ export declare function createZeusVitePlugin(options?: ZeusBundlerPluginOptions): Plugin;
149
+
150
+ export { createZeusVitePlugin as default, createZeusVitePlugin as zeus };