@lovable.dev/vite-tanstack-config 2.7.5-rc.6 → 2.7.6

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/index.d.cts CHANGED
@@ -1,5 +1,5 @@
1
- import { Plugin, PluginOption, UserConfig, ConfigEnv, UserConfigFnObject, UserConfigFnPromise, UserConfigFn } from 'vite';
2
-
1
+ import { ConfigEnv, Plugin, PluginOption, UserConfig, UserConfigFn, UserConfigFnObject, UserConfigFnPromise } from "vite";
2
+ //#region src/assetsProxyPlugin.d.ts
3
3
  /**
4
4
  * Forwards `/__l5e/assets-v1/*` requests from the Vite dev server to the
5
5
  * Lovable preview proxy so assets resolve when the page is loaded directly
@@ -10,58 +10,59 @@ import { Plugin, PluginOption, UserConfig, ConfigEnv, UserConfigFnObject, UserCo
10
10
  * `id-preview--<project-id>.lovable.app`.
11
11
  */
12
12
  declare function lovableAssetsProxyPlugin(): Plugin;
13
-
13
+ //#endregion
14
+ //#region src/index.d.ts
14
15
  interface LovableViteTanstackOptions {
15
- plugins?: PluginOption[];
16
- vite?: UserConfig;
17
- serverFnErrorLogger?: boolean;
18
- ssrErrorLogger?: boolean;
19
- /**
20
- * Options forwarded to `nitro()` from `nitro/vite`.
21
- *
22
- * Behavior:
23
- * - **undefined** (default): nitro runs on every production build, defaulting
24
- * to the `cloudflare-module` preset via Nitro's `defaultPreset` — zero-config
25
- * target auto-detection (`NITRO_PRESET`, Vercel/Netlify/Cloudflare Pages)
26
- * still wins, so a self-deploy auto-targets its own platform. If the optional
27
- * `nitro` peer dep isn't installed, it's skipped (no deploy intent to honor).
28
- * - **`true`**: same as undefined, but fails fast if the `nitro` peer dep is
29
- * missing — the explicit opt-in signals deploy intent.
30
- * - **object**: force-on, with these overrides. Set `preset`
31
- * (e.g. `{ preset: "vercel" }`) to hard-pin a target from your own CI.
32
- * - **`false`**: skip nitro entirely.
33
- *
34
- * Inside a Lovable build the preset and output layout are forced to
35
- * Cloudflare; `preset`/`output`/`cloudflare` overrides apply only outside it.
36
- *
37
- * The option surface is narrow on purpose — Nitro v3 is still pre-RC, so
38
- * we only expose stable build-time knobs to reduce churn if
39
- * `NitroPluginConfig` schema changes. File an issue if you need more.
40
- */
41
- nitro?: true | {
42
- preset?: string;
43
- output?: {
44
- dir?: string;
45
- publicDir?: string;
46
- serverDir?: string;
47
- };
48
- cloudflare?: {
49
- nodeCompat?: boolean;
50
- deployConfig?: boolean;
51
- };
52
- } | false;
53
- /** Options forwarded to tanstackStart(). */
54
- tanstackStart?: Record<string, unknown>;
55
- /** Options forwarded to viteReact(). */
56
- react?: Record<string, unknown>;
57
- /** Set to false to disable automatic VITE_* env define injection. Default: true. */
58
- envDefine?: boolean;
59
- /**
60
- * Options for the HMR gate plugin (@lovable.dev/vite-plugin-hmr-gate).
61
- * Enabled by default in sandbox mode. Set to false to disable, or pass options
62
- * to customise behaviour. Set to true or an options object to enable outside sandbox.
63
- */
64
- hmrGate?: boolean | Record<string, unknown>;
16
+ plugins?: PluginOption[];
17
+ vite?: UserConfig;
18
+ serverFnErrorLogger?: boolean;
19
+ ssrErrorLogger?: boolean;
20
+ /**
21
+ * Options forwarded to `nitro()` from `nitro/vite`.
22
+ *
23
+ * Behavior:
24
+ * - **undefined** (default): nitro runs on every production build, defaulting
25
+ * to the `cloudflare-module` preset via Nitro's `defaultPreset` — zero-config
26
+ * target auto-detection (`NITRO_PRESET`, Vercel/Netlify/Cloudflare Pages)
27
+ * still wins, so a self-deploy auto-targets its own platform. If the optional
28
+ * `nitro` peer dep isn't installed, it's skipped (no deploy intent to honor).
29
+ * - **`true`**: same as undefined, but fails fast if the `nitro` peer dep is
30
+ * missing — the explicit opt-in signals deploy intent.
31
+ * - **object**: force-on, with these overrides. Set `preset`
32
+ * (e.g. `{ preset: "vercel" }`) to hard-pin a target from your own CI.
33
+ * - **`false`**: skip nitro entirely.
34
+ *
35
+ * Inside a Lovable build the preset and output layout are forced to
36
+ * Cloudflare; `preset`/`output`/`cloudflare` overrides apply only outside it.
37
+ *
38
+ * The option surface is narrow on purpose — Nitro v3 is still pre-RC, so
39
+ * we only expose stable build-time knobs to reduce churn if
40
+ * `NitroPluginConfig` schema changes. File an issue if you need more.
41
+ */
42
+ nitro?: true | {
43
+ preset?: string;
44
+ output?: {
45
+ dir?: string;
46
+ publicDir?: string;
47
+ serverDir?: string;
48
+ };
49
+ cloudflare?: {
50
+ nodeCompat?: boolean;
51
+ deployConfig?: boolean;
52
+ };
53
+ } | false;
54
+ /** Options forwarded to tanstackStart(). */
55
+ tanstackStart?: Record<string, unknown>;
56
+ /** Options forwarded to viteReact(). */
57
+ react?: Record<string, unknown>;
58
+ /** Set to false to disable automatic VITE_* env define injection. Default: true. */
59
+ envDefine?: boolean;
60
+ /**
61
+ * Options for the HMR gate plugin (@lovable.dev/vite-plugin-hmr-gate).
62
+ * Enabled by default in sandbox mode. Set to false to disable, or pass options
63
+ * to customise behaviour. Set to true or an options object to enable outside sandbox.
64
+ */
65
+ hmrGate?: boolean | Record<string, unknown>;
65
66
  }
66
67
  declare function defineConfig(config: UserConfig): (env: ConfigEnv) => Promise<UserConfig>;
67
68
  declare function defineConfig(config: Promise<UserConfig>): (env: ConfigEnv) => Promise<UserConfig>;
@@ -69,5 +70,5 @@ declare function defineConfig(config: UserConfigFnObject): (env: ConfigEnv) => P
69
70
  declare function defineConfig(config: UserConfigFnPromise): (env: ConfigEnv) => Promise<UserConfig>;
70
71
  declare function defineConfig(config: UserConfigFn): (env: ConfigEnv) => Promise<UserConfig>;
71
72
  declare function defineConfig(options?: LovableViteTanstackOptions): (env: ConfigEnv) => Promise<UserConfig>;
72
-
73
- export { type LovableViteTanstackOptions, defineConfig, lovableAssetsProxyPlugin };
73
+ //#endregion
74
+ export { LovableViteTanstackOptions, defineConfig, lovableAssetsProxyPlugin };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { Plugin, PluginOption, UserConfig, ConfigEnv, UserConfigFnObject, UserConfigFnPromise, UserConfigFn } from 'vite';
2
-
1
+ import { ConfigEnv, Plugin, PluginOption, UserConfig, UserConfigFn, UserConfigFnObject, UserConfigFnPromise } from "vite";
2
+ //#region src/assetsProxyPlugin.d.ts
3
3
  /**
4
4
  * Forwards `/__l5e/assets-v1/*` requests from the Vite dev server to the
5
5
  * Lovable preview proxy so assets resolve when the page is loaded directly
@@ -10,58 +10,59 @@ import { Plugin, PluginOption, UserConfig, ConfigEnv, UserConfigFnObject, UserCo
10
10
  * `id-preview--<project-id>.lovable.app`.
11
11
  */
12
12
  declare function lovableAssetsProxyPlugin(): Plugin;
13
-
13
+ //#endregion
14
+ //#region src/index.d.ts
14
15
  interface LovableViteTanstackOptions {
15
- plugins?: PluginOption[];
16
- vite?: UserConfig;
17
- serverFnErrorLogger?: boolean;
18
- ssrErrorLogger?: boolean;
19
- /**
20
- * Options forwarded to `nitro()` from `nitro/vite`.
21
- *
22
- * Behavior:
23
- * - **undefined** (default): nitro runs on every production build, defaulting
24
- * to the `cloudflare-module` preset via Nitro's `defaultPreset` — zero-config
25
- * target auto-detection (`NITRO_PRESET`, Vercel/Netlify/Cloudflare Pages)
26
- * still wins, so a self-deploy auto-targets its own platform. If the optional
27
- * `nitro` peer dep isn't installed, it's skipped (no deploy intent to honor).
28
- * - **`true`**: same as undefined, but fails fast if the `nitro` peer dep is
29
- * missing — the explicit opt-in signals deploy intent.
30
- * - **object**: force-on, with these overrides. Set `preset`
31
- * (e.g. `{ preset: "vercel" }`) to hard-pin a target from your own CI.
32
- * - **`false`**: skip nitro entirely.
33
- *
34
- * Inside a Lovable build the preset and output layout are forced to
35
- * Cloudflare; `preset`/`output`/`cloudflare` overrides apply only outside it.
36
- *
37
- * The option surface is narrow on purpose — Nitro v3 is still pre-RC, so
38
- * we only expose stable build-time knobs to reduce churn if
39
- * `NitroPluginConfig` schema changes. File an issue if you need more.
40
- */
41
- nitro?: true | {
42
- preset?: string;
43
- output?: {
44
- dir?: string;
45
- publicDir?: string;
46
- serverDir?: string;
47
- };
48
- cloudflare?: {
49
- nodeCompat?: boolean;
50
- deployConfig?: boolean;
51
- };
52
- } | false;
53
- /** Options forwarded to tanstackStart(). */
54
- tanstackStart?: Record<string, unknown>;
55
- /** Options forwarded to viteReact(). */
56
- react?: Record<string, unknown>;
57
- /** Set to false to disable automatic VITE_* env define injection. Default: true. */
58
- envDefine?: boolean;
59
- /**
60
- * Options for the HMR gate plugin (@lovable.dev/vite-plugin-hmr-gate).
61
- * Enabled by default in sandbox mode. Set to false to disable, or pass options
62
- * to customise behaviour. Set to true or an options object to enable outside sandbox.
63
- */
64
- hmrGate?: boolean | Record<string, unknown>;
16
+ plugins?: PluginOption[];
17
+ vite?: UserConfig;
18
+ serverFnErrorLogger?: boolean;
19
+ ssrErrorLogger?: boolean;
20
+ /**
21
+ * Options forwarded to `nitro()` from `nitro/vite`.
22
+ *
23
+ * Behavior:
24
+ * - **undefined** (default): nitro runs on every production build, defaulting
25
+ * to the `cloudflare-module` preset via Nitro's `defaultPreset` — zero-config
26
+ * target auto-detection (`NITRO_PRESET`, Vercel/Netlify/Cloudflare Pages)
27
+ * still wins, so a self-deploy auto-targets its own platform. If the optional
28
+ * `nitro` peer dep isn't installed, it's skipped (no deploy intent to honor).
29
+ * - **`true`**: same as undefined, but fails fast if the `nitro` peer dep is
30
+ * missing — the explicit opt-in signals deploy intent.
31
+ * - **object**: force-on, with these overrides. Set `preset`
32
+ * (e.g. `{ preset: "vercel" }`) to hard-pin a target from your own CI.
33
+ * - **`false`**: skip nitro entirely.
34
+ *
35
+ * Inside a Lovable build the preset and output layout are forced to
36
+ * Cloudflare; `preset`/`output`/`cloudflare` overrides apply only outside it.
37
+ *
38
+ * The option surface is narrow on purpose — Nitro v3 is still pre-RC, so
39
+ * we only expose stable build-time knobs to reduce churn if
40
+ * `NitroPluginConfig` schema changes. File an issue if you need more.
41
+ */
42
+ nitro?: true | {
43
+ preset?: string;
44
+ output?: {
45
+ dir?: string;
46
+ publicDir?: string;
47
+ serverDir?: string;
48
+ };
49
+ cloudflare?: {
50
+ nodeCompat?: boolean;
51
+ deployConfig?: boolean;
52
+ };
53
+ } | false;
54
+ /** Options forwarded to tanstackStart(). */
55
+ tanstackStart?: Record<string, unknown>;
56
+ /** Options forwarded to viteReact(). */
57
+ react?: Record<string, unknown>;
58
+ /** Set to false to disable automatic VITE_* env define injection. Default: true. */
59
+ envDefine?: boolean;
60
+ /**
61
+ * Options for the HMR gate plugin (@lovable.dev/vite-plugin-hmr-gate).
62
+ * Enabled by default in sandbox mode. Set to false to disable, or pass options
63
+ * to customise behaviour. Set to true or an options object to enable outside sandbox.
64
+ */
65
+ hmrGate?: boolean | Record<string, unknown>;
65
66
  }
66
67
  declare function defineConfig(config: UserConfig): (env: ConfigEnv) => Promise<UserConfig>;
67
68
  declare function defineConfig(config: Promise<UserConfig>): (env: ConfigEnv) => Promise<UserConfig>;
@@ -69,5 +70,5 @@ declare function defineConfig(config: UserConfigFnObject): (env: ConfigEnv) => P
69
70
  declare function defineConfig(config: UserConfigFnPromise): (env: ConfigEnv) => Promise<UserConfig>;
70
71
  declare function defineConfig(config: UserConfigFn): (env: ConfigEnv) => Promise<UserConfig>;
71
72
  declare function defineConfig(options?: LovableViteTanstackOptions): (env: ConfigEnv) => Promise<UserConfig>;
72
-
73
- export { type LovableViteTanstackOptions, defineConfig, lovableAssetsProxyPlugin };
73
+ //#endregion
74
+ export { LovableViteTanstackOptions, defineConfig, lovableAssetsProxyPlugin };