@storybook/builder-vite 10.6.0-alpha.0 → 10.6.0-alpha.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,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_sfa2jard66 from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_sfa2jard66 from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_sfa2jard66 from "node:module";
1
+ import CJS_COMPAT_NODE_URL_bdw69tdwtqr from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_bdw69tdwtqr from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_bdw69tdwtqr from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_sfa2jard66.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_sfa2jard66.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_sfa2jard66.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_bdw69tdwtqr.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_bdw69tdwtqr.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_bdw69tdwtqr.createRequire(import.meta.url);
8
8
 
9
9
  // ------------------------------------------------------------
10
10
  // end of CJS compatibility banner, injected by Storybook's esbuild configuration
package/dist/index.d.ts CHANGED
@@ -1,35 +1,38 @@
1
- import { Builder, Options } from 'storybook/internal/types';
2
- import { UserConfig, InlineConfig, PluginOption } from 'vite';
1
+ import { Builder, Options } from "storybook/internal/types";
2
+ import { InlineConfig, PluginOption, UserConfig } from "vite";
3
3
 
4
+ //#region code/builders/builder-vite/.dts-emit/code/builders/builder-vite/src/types.d.ts
4
5
  type ViteStats = {
5
- toJson: () => any;
6
+ toJson: () => any;
6
7
  };
7
8
  type ViteBuilder = Builder<UserConfig, ViteStats>;
8
9
  type ViteFinal = (config: InlineConfig, options: Options) => InlineConfig | Promise<InlineConfig>;
9
10
  type StorybookConfigVite = {
10
- viteFinal?: ViteFinal;
11
+ viteFinal?: ViteFinal;
11
12
  };
12
13
  type BuilderOptions = {
13
- /** Path to `vite.config` file, relative to `process.cwd()`. */
14
- viteConfigPath?: string;
15
- /**
16
- * How Vite loads the config file. Equivalent to Vite's `--configLoader` CLI flag and the
17
- * `configLoader` option of `loadConfigFromFile`.
18
- *
19
- * Requires Vite 6.1.0 or higher. On older Vite versions this option is silently ignored.
20
- */
21
- configLoader?: 'bundle' | 'runner' | 'native';
14
+ /** Path to `vite.config` file, relative to `process.cwd()`. */viteConfigPath?: string;
15
+ /**
16
+ * How Vite loads the config file. Equivalent to Vite's `--configLoader` CLI flag and the
17
+ * `configLoader` option of `loadConfigFromFile`.
18
+ *
19
+ * Requires Vite 6.1.0 or higher. On older Vite versions this option is silently ignored.
20
+ */
21
+ configLoader?: 'bundle' | 'runner' | 'native';
22
22
  };
23
-
23
+ //#endregion
24
+ //#region code/builders/builder-vite/.dts-emit/code/builders/builder-vite/src/utils/without-vite-plugins.d.ts
24
25
  /** Recursively removes all plugins with the names given Resolves async plugins */
25
26
  declare const withoutVitePlugins: <TPlugin>(plugins: TPlugin[] | undefined, namesToRemove: string[]) => Promise<TPlugin[]>;
26
-
27
+ //#endregion
28
+ //#region code/builders/builder-vite/.dts-emit/code/builders/builder-vite/src/utils/has-vite-plugins.d.ts
27
29
  /**
28
30
  * Returns true if ANY of the plugins in the array have a name that matches one of the names in the
29
31
  * names array. Will resolve any promises in the array.
30
32
  */
31
33
  declare function hasVitePlugins(plugins: PluginOption[], names: string[]): Promise<boolean>;
32
-
34
+ //#endregion
35
+ //#region code/builders/builder-vite/.dts-emit/code/builders/builder-vite/src/index.d.ts
33
36
  declare function bail(): Promise<void>;
34
37
  /**
35
38
  * Returns a {@link ChangeDetectionAdapter} bound to the Vite dev server created by `start()`.
@@ -40,5 +43,5 @@ declare const changeDetectionAdapter: NonNullable<Builder<Options>['changeDetect
40
43
  declare const start: ViteBuilder['start'];
41
44
  declare const build: ViteBuilder['build'];
42
45
  declare const corePresets: string[];
43
-
44
- export { type BuilderOptions, type StorybookConfigVite, type ViteBuilder, type ViteFinal, bail, build, changeDetectionAdapter, corePresets, hasVitePlugins, start, withoutVitePlugins };
46
+ //#endregion
47
+ export { BuilderOptions, StorybookConfigVite, ViteBuilder, ViteFinal, bail, build, changeDetectionAdapter, corePresets, hasVitePlugins, start, withoutVitePlugins };
package/dist/index.js CHANGED
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_sfa2jard66 from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_sfa2jard66 from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_sfa2jard66 from "node:module";
1
+ import CJS_COMPAT_NODE_URL_bdw69tdwtqr from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_bdw69tdwtqr from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_bdw69tdwtqr from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_sfa2jard66.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_sfa2jard66.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_sfa2jard66.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_bdw69tdwtqr.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_bdw69tdwtqr.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_bdw69tdwtqr.createRequire(import.meta.url);
8
8
 
9
9
  // ------------------------------------------------------------
10
10
  // end of CJS compatibility banner, injected by Storybook's esbuild configuration
@@ -24,7 +24,7 @@ import {
24
24
  normalize,
25
25
  relative,
26
26
  viteCorePlugins
27
- } from "./_node-chunks/chunk-CZGOC2P5.js";
27
+ } from "./_node-chunks/chunk-TVJZ73TU.js";
28
28
 
29
29
  // ../../../node_modules/picocolors/picocolors.js
30
30
  var require_picocolors = __commonJS({
package/dist/preset.js CHANGED
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_sfa2jard66 from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_sfa2jard66 from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_sfa2jard66 from "node:module";
1
+ import CJS_COMPAT_NODE_URL_bdw69tdwtqr from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_bdw69tdwtqr from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_bdw69tdwtqr from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_sfa2jard66.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_sfa2jard66.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_sfa2jard66.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_bdw69tdwtqr.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_bdw69tdwtqr.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_bdw69tdwtqr.createRequire(import.meta.url);
8
8
 
9
9
  // ------------------------------------------------------------
10
10
  // end of CJS compatibility banner, injected by Storybook's esbuild configuration
@@ -12,7 +12,7 @@ var require = CJS_COMPAT_NODE_MODULE_sfa2jard66.createRequire(import.meta.url);
12
12
  import {
13
13
  optimizeViteDeps,
14
14
  viteCorePlugins
15
- } from "./_node-chunks/chunk-CZGOC2P5.js";
15
+ } from "./_node-chunks/chunk-TVJZ73TU.js";
16
16
  export {
17
17
  optimizeViteDeps,
18
18
  viteCorePlugins
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@storybook/builder-vite",
3
- "version": "10.6.0-alpha.0",
3
+ "version": "10.6.0-alpha.2",
4
4
  "description": "A Storybook builder to dev and build with Vite",
5
5
  "keywords": [
6
6
  "storybook",
@@ -47,7 +47,7 @@
47
47
  "!src/**/*"
48
48
  ],
49
49
  "dependencies": {
50
- "@storybook/csf-plugin": "10.6.0-alpha.0",
50
+ "@storybook/csf-plugin": "10.6.0-alpha.2",
51
51
  "ts-dedent": "^2.0.0"
52
52
  },
53
53
  "devDependencies": {
@@ -62,7 +62,7 @@
62
62
  "vite": "^7.0.4"
63
63
  },
64
64
  "peerDependencies": {
65
- "storybook": "^10.6.0-alpha.0",
65
+ "storybook": "^10.6.0-alpha.2",
66
66
  "vite": "^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0"
67
67
  },
68
68
  "publishConfig": {