@vertesia/build-tools 1.0.0-dev.20260227.112605Z → 1.0.0-dev.20260305.083323Z

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.
@@ -0,0 +1,45 @@
1
+ "use strict";
2
+ /**
3
+ * Vite-specific helpers for tool server development.
4
+ *
5
+ * Provides a pre-configured Vite plugin that handles SKILL.md, prompt,
6
+ * and raw file imports — the same transforms used by rollup at build time.
7
+ *
8
+ * @example
9
+ * ```typescript
10
+ * // vite.server.config.ts
11
+ * import { defineConfig } from 'vite';
12
+ * import devServer from '@hono/vite-dev-server';
13
+ * import { vertesiaDevServerPlugin } from '@vertesia/build-tools/vite';
14
+ *
15
+ * export default defineConfig({
16
+ * plugins: [
17
+ * vertesiaDevServerPlugin(),
18
+ * devServer({ entry: 'tools/server.ts' }),
19
+ * ],
20
+ * });
21
+ * ```
22
+ */
23
+ Object.defineProperty(exports, "__esModule", { value: true });
24
+ exports.vertesiaDevServerPlugin = vertesiaDevServerPlugin;
25
+ const plugin_js_1 = require("./plugin.js");
26
+ const index_js_1 = require("./presets/index.js");
27
+ /**
28
+ * Creates a pre-configured Vite plugin for tool server dev mode.
29
+ * Includes skill, prompt, and raw file transformers with asset copying disabled
30
+ * (assets are only needed at build time, not during dev).
31
+ *
32
+ * @param overrides - Optional overrides for the plugin config
33
+ */
34
+ function vertesiaDevServerPlugin(overrides) {
35
+ return (0, plugin_js_1.vertesiaImportPlugin)({
36
+ transformers: [
37
+ index_js_1.skillTransformer,
38
+ index_js_1.promptTransformer,
39
+ index_js_1.rawTransformer,
40
+ ],
41
+ assetsDir: false,
42
+ ...overrides,
43
+ });
44
+ }
45
+ //# sourceMappingURL=vite.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite.js","sourceRoot":"","sources":["../../src/vite.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;;AAcH,0DAUC;AArBD,2CAAmD;AACnD,iDAAyF;AAGzF;;;;;;GAMG;AACH,SAAgB,uBAAuB,CAAC,SAAiC;IACrE,OAAO,IAAA,gCAAoB,EAAC;QACxB,YAAY,EAAE;YACV,2BAAgB;YAChB,4BAAiB;YACjB,yBAAc;SACjB;QACD,SAAS,EAAE,KAAK;QAChB,GAAG,SAAS;KACf,CAAC,CAAC;AACP,CAAC"}
@@ -0,0 +1,42 @@
1
+ /**
2
+ * Vite-specific helpers for tool server development.
3
+ *
4
+ * Provides a pre-configured Vite plugin that handles SKILL.md, prompt,
5
+ * and raw file imports — the same transforms used by rollup at build time.
6
+ *
7
+ * @example
8
+ * ```typescript
9
+ * // vite.server.config.ts
10
+ * import { defineConfig } from 'vite';
11
+ * import devServer from '@hono/vite-dev-server';
12
+ * import { vertesiaDevServerPlugin } from '@vertesia/build-tools/vite';
13
+ *
14
+ * export default defineConfig({
15
+ * plugins: [
16
+ * vertesiaDevServerPlugin(),
17
+ * devServer({ entry: 'tools/server.ts' }),
18
+ * ],
19
+ * });
20
+ * ```
21
+ */
22
+ import { vertesiaImportPlugin } from './plugin.js';
23
+ import { skillTransformer, rawTransformer, promptTransformer } from './presets/index.js';
24
+ /**
25
+ * Creates a pre-configured Vite plugin for tool server dev mode.
26
+ * Includes skill, prompt, and raw file transformers with asset copying disabled
27
+ * (assets are only needed at build time, not during dev).
28
+ *
29
+ * @param overrides - Optional overrides for the plugin config
30
+ */
31
+ export function vertesiaDevServerPlugin(overrides) {
32
+ return vertesiaImportPlugin({
33
+ transformers: [
34
+ skillTransformer,
35
+ promptTransformer,
36
+ rawTransformer,
37
+ ],
38
+ assetsDir: false,
39
+ ...overrides,
40
+ });
41
+ }
42
+ //# sourceMappingURL=vite.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite.js","sourceRoot":"","sources":["../../src/vite.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAGH,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,gBAAgB,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAGzF;;;;;;GAMG;AACH,MAAM,UAAU,uBAAuB,CAAC,SAAiC;IACrE,OAAO,oBAAoB,CAAC;QACxB,YAAY,EAAE;YACV,gBAAgB;YAChB,iBAAiB;YACjB,cAAc;SACjB;QACD,SAAS,EAAE,KAAK;QAChB,GAAG,SAAS;KACf,CAAC,CAAC;AACP,CAAC"}
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Vite-specific helpers for tool server development.
3
+ *
4
+ * Provides a pre-configured Vite plugin that handles SKILL.md, prompt,
5
+ * and raw file imports — the same transforms used by rollup at build time.
6
+ *
7
+ * @example
8
+ * ```typescript
9
+ * // vite.server.config.ts
10
+ * import { defineConfig } from 'vite';
11
+ * import devServer from '@hono/vite-dev-server';
12
+ * import { vertesiaDevServerPlugin } from '@vertesia/build-tools/vite';
13
+ *
14
+ * export default defineConfig({
15
+ * plugins: [
16
+ * vertesiaDevServerPlugin(),
17
+ * devServer({ entry: 'tools/server.ts' }),
18
+ * ],
19
+ * });
20
+ * ```
21
+ */
22
+ import type { Plugin } from 'rollup';
23
+ import type { PluginConfig } from './types.js';
24
+ /**
25
+ * Creates a pre-configured Vite plugin for tool server dev mode.
26
+ * Includes skill, prompt, and raw file transformers with asset copying disabled
27
+ * (assets are only needed at build time, not during dev).
28
+ *
29
+ * @param overrides - Optional overrides for the plugin config
30
+ */
31
+ export declare function vertesiaDevServerPlugin(overrides?: Partial<PluginConfig>): Plugin;
32
+ //# sourceMappingURL=vite.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite.d.ts","sourceRoot":"","sources":["../../src/vite.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAGrC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAE/C;;;;;;GAMG;AACH,wBAAgB,uBAAuB,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC,YAAY,CAAC,GAAG,MAAM,CAUjF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vertesia/build-tools",
3
- "version": "1.0.0-dev.20260227.112605Z",
3
+ "version": "1.0.0-dev.20260305.083323Z",
4
4
  "description": "Build tools for Vertesia projects - Rollup and Vite plugins for transforming imports, bundling skills, and compiling widgets",
5
5
  "type": "module",
6
6
  "main": "./lib/esm/index.js",
@@ -29,8 +29,8 @@
29
29
  "dependencies": {
30
30
  "gray-matter": "^4.0.3",
31
31
  "zod": "^3.24.1",
32
- "@vertesia/common": "1.0.0-dev.20260227.112605Z",
33
- "@llumiverse/common": "1.0.0-dev.20260224.234313Z"
32
+ "@llumiverse/common": "1.0.0-dev.20260224.234313Z",
33
+ "@vertesia/common": "1.0.0-dev.20260305.083323Z"
34
34
  },
35
35
  "peerDependencies": {
36
36
  "rollup": "^4.59.0"
package/src/vite.ts ADDED
@@ -0,0 +1,45 @@
1
+ /**
2
+ * Vite-specific helpers for tool server development.
3
+ *
4
+ * Provides a pre-configured Vite plugin that handles SKILL.md, prompt,
5
+ * and raw file imports — the same transforms used by rollup at build time.
6
+ *
7
+ * @example
8
+ * ```typescript
9
+ * // vite.server.config.ts
10
+ * import { defineConfig } from 'vite';
11
+ * import devServer from '@hono/vite-dev-server';
12
+ * import { vertesiaDevServerPlugin } from '@vertesia/build-tools/vite';
13
+ *
14
+ * export default defineConfig({
15
+ * plugins: [
16
+ * vertesiaDevServerPlugin(),
17
+ * devServer({ entry: 'tools/server.ts' }),
18
+ * ],
19
+ * });
20
+ * ```
21
+ */
22
+
23
+ import type { Plugin } from 'rollup';
24
+ import { vertesiaImportPlugin } from './plugin.js';
25
+ import { skillTransformer, rawTransformer, promptTransformer } from './presets/index.js';
26
+ import type { PluginConfig } from './types.js';
27
+
28
+ /**
29
+ * Creates a pre-configured Vite plugin for tool server dev mode.
30
+ * Includes skill, prompt, and raw file transformers with asset copying disabled
31
+ * (assets are only needed at build time, not during dev).
32
+ *
33
+ * @param overrides - Optional overrides for the plugin config
34
+ */
35
+ export function vertesiaDevServerPlugin(overrides?: Partial<PluginConfig>): Plugin {
36
+ return vertesiaImportPlugin({
37
+ transformers: [
38
+ skillTransformer,
39
+ promptTransformer,
40
+ rawTransformer,
41
+ ],
42
+ assetsDir: false,
43
+ ...overrides,
44
+ });
45
+ }