@lovable.dev/vite-tanstack-config 2.25.0 → 2.25.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.
- package/dist/devModulePreload-BwVYdLe9.cjs +160 -0
- package/dist/devModulePreload-Dz3PBhzO.js +160 -0
- package/dist/index.cjs +3 -1
- package/dist/index.js +3 -1
- package/package.json +5 -5
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
let node_path = require("node:path");
|
|
2
|
+
let vite = require("vite");
|
|
3
|
+
//#region src/devModulePreload.ts
|
|
4
|
+
const DEV_CLIENT_ENTRY = "virtual:tanstack-start-dev-client-entry";
|
|
5
|
+
const MAX_PRELOADED_MODULES = 500;
|
|
6
|
+
const HEAD_SCAN_LIMIT = 64 * 1024;
|
|
7
|
+
const HEAD_OPEN_RE = /<head(?:\s[^>]*)?>/i;
|
|
8
|
+
const KNOWN_JS_SRC_RE = /\.(?:[jt]sx?|m[jt]s|vue|marko|svelte|astro|imba|mdx)(?:$|\?)/;
|
|
9
|
+
/** Preloads the dev client's module graph so the browser fetches it in parallel, not one import level per round trip. */
|
|
10
|
+
function devModulePreloadPlugin(options = {}) {
|
|
11
|
+
const entry = options.entry ?? DEV_CLIENT_ENTRY;
|
|
12
|
+
return {
|
|
13
|
+
name: "lovable:dev-module-preload",
|
|
14
|
+
apply: "serve",
|
|
15
|
+
configureServer(server) {
|
|
16
|
+
if (process.env["LOVABLE_DEV_MODULE_PRELOAD"] !== "1") return;
|
|
17
|
+
if (server.config.experimental?.bundledDev) return;
|
|
18
|
+
const client = server.environments?.client;
|
|
19
|
+
if (!client) return;
|
|
20
|
+
let crawl;
|
|
21
|
+
const recrawl = () => {
|
|
22
|
+
crawl ??= crawlModuleGraph(client, entry).finally(() => {
|
|
23
|
+
crawl = void 0;
|
|
24
|
+
});
|
|
25
|
+
};
|
|
26
|
+
server.httpServer?.once("listening", recrawl);
|
|
27
|
+
server.middlewares.use((req, res, next) => {
|
|
28
|
+
if (req.method === "GET" && (req.headers.accept ?? "").includes("text/html")) {
|
|
29
|
+
recrawl();
|
|
30
|
+
injectAfterHead(res, () => modulePreloadTags(preloadUrls(client, entry, server.config.base)));
|
|
31
|
+
}
|
|
32
|
+
next();
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
async function crawlModuleGraph(env, entry) {
|
|
38
|
+
const queued = /* @__PURE__ */ new Set([entry]);
|
|
39
|
+
let level = [entry];
|
|
40
|
+
while (level.length > 0) {
|
|
41
|
+
const next = [];
|
|
42
|
+
await Promise.all(level.map(async (url) => {
|
|
43
|
+
try {
|
|
44
|
+
await env.transformRequest(url);
|
|
45
|
+
const mod = await env.moduleGraph.getModuleByUrl(url);
|
|
46
|
+
for (const dep of mod?.importedModules ?? []) {
|
|
47
|
+
if (dep.id === null || queued.has(dep.url) || queued.size >= MAX_PRELOADED_MODULES) continue;
|
|
48
|
+
queued.add(dep.url);
|
|
49
|
+
next.push(dep.url);
|
|
50
|
+
}
|
|
51
|
+
} catch {}
|
|
52
|
+
}));
|
|
53
|
+
level = next;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
function preloadUrls(env, entry, base) {
|
|
57
|
+
const root = env.moduleGraph.urlToModuleMap.get(entry);
|
|
58
|
+
const queue = root ? [root] : [];
|
|
59
|
+
const seen = new Set(queue);
|
|
60
|
+
const urls = [];
|
|
61
|
+
for (const mod of queue) {
|
|
62
|
+
const code = mod.transformResult?.code ?? "";
|
|
63
|
+
for (const dep of mod.importedModules) {
|
|
64
|
+
if (seen.has(dep) || !dep.transformResult) continue;
|
|
65
|
+
const url = browserImportUrl(dep, base);
|
|
66
|
+
if (!code.includes(`"${url}"`) && !code.includes(`'${url}'`)) continue;
|
|
67
|
+
if (urls.length === MAX_PRELOADED_MODULES) return urls;
|
|
68
|
+
seen.add(dep);
|
|
69
|
+
queue.push(dep);
|
|
70
|
+
urls.push(url);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
return urls;
|
|
74
|
+
}
|
|
75
|
+
function browserImportUrl(mod, base) {
|
|
76
|
+
let url = mod.url.startsWith("/") ? mod.url : `/@id/${mod.url.replace("\0", "__x00__")}`;
|
|
77
|
+
if (mod.lastHMRTimestamp > 0) url = injectQuery(url, `t=${mod.lastHMRTimestamp}`);
|
|
78
|
+
if (!isJSRequest(url) && !(0, vite.isCSSRequest)(url)) url = injectQuery(url, "import");
|
|
79
|
+
return base === "/" ? url : `${base.replace(/\/$/, "")}${url}`;
|
|
80
|
+
}
|
|
81
|
+
function injectQuery(url, query) {
|
|
82
|
+
const at = url.search(/[?#]/);
|
|
83
|
+
if (at === -1) return `${url}?${query}`;
|
|
84
|
+
const postfix = url.slice(at);
|
|
85
|
+
return `${url.slice(0, at)}?${query}${postfix[0] === "?" ? `&${postfix.slice(1)}` : postfix}`;
|
|
86
|
+
}
|
|
87
|
+
function isJSRequest(url) {
|
|
88
|
+
const path = url.replace(/[?#].*$/, "");
|
|
89
|
+
return KNOWN_JS_SRC_RE.test(path) || !node_path.posix.extname(path) && !path.endsWith("/");
|
|
90
|
+
}
|
|
91
|
+
function modulePreloadTags(urls) {
|
|
92
|
+
const escape = (url) => url.replace(/&/g, "&").replace(/"/g, """).replace(/</g, "<");
|
|
93
|
+
return urls.map((url) => `<link rel="modulepreload" href="${escape(url)}">`).join("");
|
|
94
|
+
}
|
|
95
|
+
function headerPairs(headers) {
|
|
96
|
+
if (!Array.isArray(headers)) return Object.entries(headers);
|
|
97
|
+
if (Array.isArray(headers[0])) return headers;
|
|
98
|
+
return headers.flatMap((value, i) => i % 2 === 0 ? [[value, headers[i + 1]]] : []);
|
|
99
|
+
}
|
|
100
|
+
function withoutContentLength(headers) {
|
|
101
|
+
const isLength = (name) => String(name).toLowerCase() === "content-length";
|
|
102
|
+
if (!Array.isArray(headers)) return Object.fromEntries(Object.entries(headers).filter(([name]) => !isLength(name)));
|
|
103
|
+
if (Array.isArray(headers[0])) return headers.filter((pair) => !isLength(pair[0]));
|
|
104
|
+
return headers.filter((_, i) => !isLength(headers[i - i % 2]));
|
|
105
|
+
}
|
|
106
|
+
/** Splices tags after the opening `<head>` of an unencoded HTML response, keeping every original byte. */
|
|
107
|
+
function injectAfterHead(res, tags) {
|
|
108
|
+
const declared = /* @__PURE__ */ new Map();
|
|
109
|
+
const header = (name) => declared.get(name) ?? String(res.getHeader(name) ?? "");
|
|
110
|
+
const isPlainHtml = () => /text\/html/i.test(header("content-type")) && /^(identity)?$/i.test(header("content-encoding").trim());
|
|
111
|
+
let searching = true;
|
|
112
|
+
let scanned = 0;
|
|
113
|
+
const splice = (chunk, encoding) => {
|
|
114
|
+
if (!searching || chunk == null || typeof chunk === "function") return chunk;
|
|
115
|
+
const isBytes = chunk instanceof Uint8Array;
|
|
116
|
+
const isUtf8String = typeof chunk === "string" && (typeof encoding !== "string" || /^utf-?8$/i.test(encoding));
|
|
117
|
+
if (!isPlainHtml() || !(isBytes || isUtf8String)) {
|
|
118
|
+
searching = false;
|
|
119
|
+
return chunk;
|
|
120
|
+
}
|
|
121
|
+
const budget = HEAD_SCAN_LIMIT - scanned;
|
|
122
|
+
const text = isBytes ? Buffer.from(chunk.buffer, chunk.byteOffset, Math.min(chunk.byteLength, budget)).toString("latin1") : chunk.slice(0, budget);
|
|
123
|
+
const match = HEAD_OPEN_RE.exec(text);
|
|
124
|
+
if (!match) {
|
|
125
|
+
scanned += text.length;
|
|
126
|
+
searching = scanned < HEAD_SCAN_LIMIT;
|
|
127
|
+
return chunk;
|
|
128
|
+
}
|
|
129
|
+
searching = false;
|
|
130
|
+
const at = match.index + match[0].length;
|
|
131
|
+
let inserted = "";
|
|
132
|
+
try {
|
|
133
|
+
inserted = tags();
|
|
134
|
+
} catch {
|
|
135
|
+
return chunk;
|
|
136
|
+
}
|
|
137
|
+
if (!isBytes) return `${chunk.slice(0, at)}${inserted}${chunk.slice(at)}`;
|
|
138
|
+
return Buffer.concat([
|
|
139
|
+
chunk.subarray(0, at),
|
|
140
|
+
Buffer.from(inserted, "utf8"),
|
|
141
|
+
chunk.subarray(at)
|
|
142
|
+
]);
|
|
143
|
+
};
|
|
144
|
+
const writeHead = res.writeHead.bind(res);
|
|
145
|
+
const write = res.write.bind(res);
|
|
146
|
+
const end = res.end.bind(res);
|
|
147
|
+
res.writeHead = ((status, ...rest) => {
|
|
148
|
+
const at = rest.findIndex((arg) => arg !== null && typeof arg === "object");
|
|
149
|
+
if (at !== -1) for (const [name, value] of headerPairs(rest[at])) declared.set(String(name).toLowerCase(), String(value));
|
|
150
|
+
if (isPlainHtml()) {
|
|
151
|
+
res.removeHeader("content-length");
|
|
152
|
+
if (at !== -1) rest[at] = withoutContentLength(rest[at]);
|
|
153
|
+
}
|
|
154
|
+
return writeHead(status, ...rest);
|
|
155
|
+
});
|
|
156
|
+
res.write = ((chunk, ...rest) => write(splice(chunk, rest[0]), ...rest));
|
|
157
|
+
res.end = ((chunk, ...rest) => end(splice(chunk, rest[0]), ...rest));
|
|
158
|
+
}
|
|
159
|
+
//#endregion
|
|
160
|
+
exports.devModulePreloadPlugin = devModulePreloadPlugin;
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
import { posix } from "node:path";
|
|
2
|
+
import { isCSSRequest } from "vite";
|
|
3
|
+
//#region src/devModulePreload.ts
|
|
4
|
+
const DEV_CLIENT_ENTRY = "virtual:tanstack-start-dev-client-entry";
|
|
5
|
+
const MAX_PRELOADED_MODULES = 500;
|
|
6
|
+
const HEAD_SCAN_LIMIT = 64 * 1024;
|
|
7
|
+
const HEAD_OPEN_RE = /<head(?:\s[^>]*)?>/i;
|
|
8
|
+
const KNOWN_JS_SRC_RE = /\.(?:[jt]sx?|m[jt]s|vue|marko|svelte|astro|imba|mdx)(?:$|\?)/;
|
|
9
|
+
/** Preloads the dev client's module graph so the browser fetches it in parallel, not one import level per round trip. */
|
|
10
|
+
function devModulePreloadPlugin(options = {}) {
|
|
11
|
+
const entry = options.entry ?? DEV_CLIENT_ENTRY;
|
|
12
|
+
return {
|
|
13
|
+
name: "lovable:dev-module-preload",
|
|
14
|
+
apply: "serve",
|
|
15
|
+
configureServer(server) {
|
|
16
|
+
if (process.env["LOVABLE_DEV_MODULE_PRELOAD"] !== "1") return;
|
|
17
|
+
if (server.config.experimental?.bundledDev) return;
|
|
18
|
+
const client = server.environments?.client;
|
|
19
|
+
if (!client) return;
|
|
20
|
+
let crawl;
|
|
21
|
+
const recrawl = () => {
|
|
22
|
+
crawl ??= crawlModuleGraph(client, entry).finally(() => {
|
|
23
|
+
crawl = void 0;
|
|
24
|
+
});
|
|
25
|
+
};
|
|
26
|
+
server.httpServer?.once("listening", recrawl);
|
|
27
|
+
server.middlewares.use((req, res, next) => {
|
|
28
|
+
if (req.method === "GET" && (req.headers.accept ?? "").includes("text/html")) {
|
|
29
|
+
recrawl();
|
|
30
|
+
injectAfterHead(res, () => modulePreloadTags(preloadUrls(client, entry, server.config.base)));
|
|
31
|
+
}
|
|
32
|
+
next();
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
async function crawlModuleGraph(env, entry) {
|
|
38
|
+
const queued = /* @__PURE__ */ new Set([entry]);
|
|
39
|
+
let level = [entry];
|
|
40
|
+
while (level.length > 0) {
|
|
41
|
+
const next = [];
|
|
42
|
+
await Promise.all(level.map(async (url) => {
|
|
43
|
+
try {
|
|
44
|
+
await env.transformRequest(url);
|
|
45
|
+
const mod = await env.moduleGraph.getModuleByUrl(url);
|
|
46
|
+
for (const dep of mod?.importedModules ?? []) {
|
|
47
|
+
if (dep.id === null || queued.has(dep.url) || queued.size >= MAX_PRELOADED_MODULES) continue;
|
|
48
|
+
queued.add(dep.url);
|
|
49
|
+
next.push(dep.url);
|
|
50
|
+
}
|
|
51
|
+
} catch {}
|
|
52
|
+
}));
|
|
53
|
+
level = next;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
function preloadUrls(env, entry, base) {
|
|
57
|
+
const root = env.moduleGraph.urlToModuleMap.get(entry);
|
|
58
|
+
const queue = root ? [root] : [];
|
|
59
|
+
const seen = new Set(queue);
|
|
60
|
+
const urls = [];
|
|
61
|
+
for (const mod of queue) {
|
|
62
|
+
const code = mod.transformResult?.code ?? "";
|
|
63
|
+
for (const dep of mod.importedModules) {
|
|
64
|
+
if (seen.has(dep) || !dep.transformResult) continue;
|
|
65
|
+
const url = browserImportUrl(dep, base);
|
|
66
|
+
if (!code.includes(`"${url}"`) && !code.includes(`'${url}'`)) continue;
|
|
67
|
+
if (urls.length === MAX_PRELOADED_MODULES) return urls;
|
|
68
|
+
seen.add(dep);
|
|
69
|
+
queue.push(dep);
|
|
70
|
+
urls.push(url);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
return urls;
|
|
74
|
+
}
|
|
75
|
+
function browserImportUrl(mod, base) {
|
|
76
|
+
let url = mod.url.startsWith("/") ? mod.url : `/@id/${mod.url.replace("\0", "__x00__")}`;
|
|
77
|
+
if (mod.lastHMRTimestamp > 0) url = injectQuery(url, `t=${mod.lastHMRTimestamp}`);
|
|
78
|
+
if (!isJSRequest(url) && !isCSSRequest(url)) url = injectQuery(url, "import");
|
|
79
|
+
return base === "/" ? url : `${base.replace(/\/$/, "")}${url}`;
|
|
80
|
+
}
|
|
81
|
+
function injectQuery(url, query) {
|
|
82
|
+
const at = url.search(/[?#]/);
|
|
83
|
+
if (at === -1) return `${url}?${query}`;
|
|
84
|
+
const postfix = url.slice(at);
|
|
85
|
+
return `${url.slice(0, at)}?${query}${postfix[0] === "?" ? `&${postfix.slice(1)}` : postfix}`;
|
|
86
|
+
}
|
|
87
|
+
function isJSRequest(url) {
|
|
88
|
+
const path = url.replace(/[?#].*$/, "");
|
|
89
|
+
return KNOWN_JS_SRC_RE.test(path) || !posix.extname(path) && !path.endsWith("/");
|
|
90
|
+
}
|
|
91
|
+
function modulePreloadTags(urls) {
|
|
92
|
+
const escape = (url) => url.replace(/&/g, "&").replace(/"/g, """).replace(/</g, "<");
|
|
93
|
+
return urls.map((url) => `<link rel="modulepreload" href="${escape(url)}">`).join("");
|
|
94
|
+
}
|
|
95
|
+
function headerPairs(headers) {
|
|
96
|
+
if (!Array.isArray(headers)) return Object.entries(headers);
|
|
97
|
+
if (Array.isArray(headers[0])) return headers;
|
|
98
|
+
return headers.flatMap((value, i) => i % 2 === 0 ? [[value, headers[i + 1]]] : []);
|
|
99
|
+
}
|
|
100
|
+
function withoutContentLength(headers) {
|
|
101
|
+
const isLength = (name) => String(name).toLowerCase() === "content-length";
|
|
102
|
+
if (!Array.isArray(headers)) return Object.fromEntries(Object.entries(headers).filter(([name]) => !isLength(name)));
|
|
103
|
+
if (Array.isArray(headers[0])) return headers.filter((pair) => !isLength(pair[0]));
|
|
104
|
+
return headers.filter((_, i) => !isLength(headers[i - i % 2]));
|
|
105
|
+
}
|
|
106
|
+
/** Splices tags after the opening `<head>` of an unencoded HTML response, keeping every original byte. */
|
|
107
|
+
function injectAfterHead(res, tags) {
|
|
108
|
+
const declared = /* @__PURE__ */ new Map();
|
|
109
|
+
const header = (name) => declared.get(name) ?? String(res.getHeader(name) ?? "");
|
|
110
|
+
const isPlainHtml = () => /text\/html/i.test(header("content-type")) && /^(identity)?$/i.test(header("content-encoding").trim());
|
|
111
|
+
let searching = true;
|
|
112
|
+
let scanned = 0;
|
|
113
|
+
const splice = (chunk, encoding) => {
|
|
114
|
+
if (!searching || chunk == null || typeof chunk === "function") return chunk;
|
|
115
|
+
const isBytes = chunk instanceof Uint8Array;
|
|
116
|
+
const isUtf8String = typeof chunk === "string" && (typeof encoding !== "string" || /^utf-?8$/i.test(encoding));
|
|
117
|
+
if (!isPlainHtml() || !(isBytes || isUtf8String)) {
|
|
118
|
+
searching = false;
|
|
119
|
+
return chunk;
|
|
120
|
+
}
|
|
121
|
+
const budget = HEAD_SCAN_LIMIT - scanned;
|
|
122
|
+
const text = isBytes ? Buffer.from(chunk.buffer, chunk.byteOffset, Math.min(chunk.byteLength, budget)).toString("latin1") : chunk.slice(0, budget);
|
|
123
|
+
const match = HEAD_OPEN_RE.exec(text);
|
|
124
|
+
if (!match) {
|
|
125
|
+
scanned += text.length;
|
|
126
|
+
searching = scanned < HEAD_SCAN_LIMIT;
|
|
127
|
+
return chunk;
|
|
128
|
+
}
|
|
129
|
+
searching = false;
|
|
130
|
+
const at = match.index + match[0].length;
|
|
131
|
+
let inserted = "";
|
|
132
|
+
try {
|
|
133
|
+
inserted = tags();
|
|
134
|
+
} catch {
|
|
135
|
+
return chunk;
|
|
136
|
+
}
|
|
137
|
+
if (!isBytes) return `${chunk.slice(0, at)}${inserted}${chunk.slice(at)}`;
|
|
138
|
+
return Buffer.concat([
|
|
139
|
+
chunk.subarray(0, at),
|
|
140
|
+
Buffer.from(inserted, "utf8"),
|
|
141
|
+
chunk.subarray(at)
|
|
142
|
+
]);
|
|
143
|
+
};
|
|
144
|
+
const writeHead = res.writeHead.bind(res);
|
|
145
|
+
const write = res.write.bind(res);
|
|
146
|
+
const end = res.end.bind(res);
|
|
147
|
+
res.writeHead = ((status, ...rest) => {
|
|
148
|
+
const at = rest.findIndex((arg) => arg !== null && typeof arg === "object");
|
|
149
|
+
if (at !== -1) for (const [name, value] of headerPairs(rest[at])) declared.set(String(name).toLowerCase(), String(value));
|
|
150
|
+
if (isPlainHtml()) {
|
|
151
|
+
res.removeHeader("content-length");
|
|
152
|
+
if (at !== -1) rest[at] = withoutContentLength(rest[at]);
|
|
153
|
+
}
|
|
154
|
+
return writeHead(status, ...rest);
|
|
155
|
+
});
|
|
156
|
+
res.write = ((chunk, ...rest) => write(splice(chunk, rest[0]), ...rest));
|
|
157
|
+
res.end = ((chunk, ...rest) => end(splice(chunk, rest[0]), ...rest));
|
|
158
|
+
}
|
|
159
|
+
//#endregion
|
|
160
|
+
export { devModulePreloadPlugin };
|
package/dist/index.cjs
CHANGED
|
@@ -105,7 +105,7 @@ function lovableAssetsProxyPlugin() {
|
|
|
105
105
|
//#endregion
|
|
106
106
|
//#region package.json
|
|
107
107
|
var name = "@lovable.dev/vite-tanstack-config";
|
|
108
|
-
var version = "2.25.
|
|
108
|
+
var version = "2.25.2";
|
|
109
109
|
//#endregion
|
|
110
110
|
//#region src/logging.ts
|
|
111
111
|
const PACKAGE_NAME = "@lovable.dev/vite-tanstack-config";
|
|
@@ -1851,6 +1851,8 @@ function defineConfig(configOrOptions = {}) {
|
|
|
1851
1851
|
internalPlugins.push(linkedDependenciesPlugin());
|
|
1852
1852
|
const { devServerBridgePlugin } = await Promise.resolve().then(() => require("./dev-server-bridge.cjs"));
|
|
1853
1853
|
internalPlugins.push(devServerBridgePlugin());
|
|
1854
|
+
const { devModulePreloadPlugin } = await Promise.resolve().then(() => require("./devModulePreload-BwVYdLe9.cjs"));
|
|
1855
|
+
internalPlugins.push(devModulePreloadPlugin());
|
|
1854
1856
|
}
|
|
1855
1857
|
if (command === "serve") internalPlugins.push(lovableAssetsProxyPlugin());
|
|
1856
1858
|
let envDefine = {};
|
package/dist/index.js
CHANGED
|
@@ -81,7 +81,7 @@ function lovableAssetsProxyPlugin() {
|
|
|
81
81
|
//#endregion
|
|
82
82
|
//#region package.json
|
|
83
83
|
var name = "@lovable.dev/vite-tanstack-config";
|
|
84
|
-
var version = "2.25.
|
|
84
|
+
var version = "2.25.2";
|
|
85
85
|
//#endregion
|
|
86
86
|
//#region src/logging.ts
|
|
87
87
|
const PACKAGE_NAME = "@lovable.dev/vite-tanstack-config";
|
|
@@ -1827,6 +1827,8 @@ function defineConfig(configOrOptions = {}) {
|
|
|
1827
1827
|
internalPlugins.push(linkedDependenciesPlugin());
|
|
1828
1828
|
const { devServerBridgePlugin } = await import("./dev-server-bridge.js");
|
|
1829
1829
|
internalPlugins.push(devServerBridgePlugin());
|
|
1830
|
+
const { devModulePreloadPlugin } = await import("./devModulePreload-Dz3PBhzO.js");
|
|
1831
|
+
internalPlugins.push(devModulePreloadPlugin());
|
|
1830
1832
|
}
|
|
1831
1833
|
if (command === "serve") internalPlugins.push(lovableAssetsProxyPlugin());
|
|
1832
1834
|
let envDefine = {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lovable.dev/vite-tanstack-config",
|
|
3
|
-
"version": "2.25.
|
|
3
|
+
"version": "2.25.2",
|
|
4
4
|
"description": "Vite config wrapper for Lovable TanStack Start projects",
|
|
5
5
|
"main": "./dist/index.cjs",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -83,9 +83,9 @@
|
|
|
83
83
|
"devDependencies": {
|
|
84
84
|
"@tailwindcss/vite": "^4.3.0",
|
|
85
85
|
"@tanstack/react-query": "^5.102.8",
|
|
86
|
-
"@tanstack/react-router": "1.170.
|
|
87
|
-
"@tanstack/react-start": "^1.
|
|
88
|
-
"@tanstack/router-generator": "^1.167.
|
|
86
|
+
"@tanstack/react-router": "1.170.38",
|
|
87
|
+
"@tanstack/react-start": "^1.168.57",
|
|
88
|
+
"@tanstack/router-generator": "^1.167.38",
|
|
89
89
|
"@types/node": "22.13.13",
|
|
90
90
|
"@vitejs/plugin-react": "^5.2.0",
|
|
91
91
|
"nitro": "3.0.260603-beta",
|
|
@@ -106,7 +106,7 @@
|
|
|
106
106
|
"scripts": {
|
|
107
107
|
"build": "tsdown",
|
|
108
108
|
"check:package": "tmp=$(mktemp -d) && pnpm pack --out \"$tmp/pkg.tgz\" && tar -xzf \"$tmp/pkg.tgz\" -C \"$tmp\" && publint \"$tmp/package\" --strict && attw \"$tmp/pkg.tgz\"",
|
|
109
|
-
"typecheck": "
|
|
109
|
+
"typecheck": "tsc --noEmit --rootDir ../..",
|
|
110
110
|
"dev": "tsdown --watch",
|
|
111
111
|
"test": "vitest run",
|
|
112
112
|
"test:unit": "vitest run --project unit",
|