fix: Vite 5 manifest does not always contain imports key

This commit is contained in:
Tom Moor
2023-11-23 10:09:30 -05:00
parent 86494461cf
commit 0e4dbbef1f

View File

@@ -36,7 +36,7 @@ if (env.isProduction) {
file: string
): string[] => [
manifest[file]["file"],
...manifest[file]["imports"].map(
...(manifest[file]["imports"] ?? []).map(
(entry: string) => manifest[entry]["file"]
),
];