Merge pull request 'chore: add three devtools debug mode' (#5) from feat/code-review into develop
🔍 Lint / 🪄 Check lint (push) Has been cancelled
🔍 Lint / 🎨 Check format (push) Has been cancelled
🔍 Lint / 🔎 Typecheck (push) Has been cancelled
🔍 Lint / 🏗 Build (push) Has been cancelled
📊 Quality / 🔒 Security Audit (push) Has been cancelled
📊 Quality / 📋 Dependency Freshness (push) Has been cancelled
📊 Quality / 📦 Bundle Size (push) Has been cancelled

Reviewed-on: #5
This commit was merged in pull request #5.
This commit is contained in:
2026-05-12 14:05:33 +00:00
3 changed files with 35 additions and 14 deletions
+1
View File
@@ -8,6 +8,7 @@
},
"scripts": {
"dev": "vite",
"dev:three-debug": "vite --mode three-debug --host 0.0.0.0",
"build": "tsc -b && vite build",
"lint": "eslint .",
"lint:fix": "eslint . --fix",
+1 -1
View File
@@ -52,7 +52,7 @@ export const REPAIR_MISSIONS: Record<RepairMissionId, RepairMissionConfig> = {
description:
"Repair the damaged cooling module before relaunching the bike",
modelPath: "/models/ebike/model.gltf",
modelScale: 0.0055,
modelScale: 0.50,
stageUiPath: "/assets/UI/ebike.webm",
interactUiPath: REPAIR_INTERACT_UI_PATH,
brokenUiPath: REPAIR_BROKEN_UI_PATH,
+33 -13
View File
@@ -9,6 +9,9 @@ import { parseMapNodes } from "./src/utils/map/mapNodeValidation";
import { parseSrt } from "./src/utils/subtitles/parseSrt";
const __dirname = fileURLToPath(new URL(".", import.meta.url));
const THREE_SOURCE_ENTRY = fileURLToPath(
new URL("./node_modules/three/src/Three.js", import.meta.url),
);
const MAX_MAP_PAYLOAD_BYTES = 1024 * 1024;
const MAX_SRT_PAYLOAD_BYTES = 256 * 1024;
@@ -634,18 +637,35 @@ function resolvePublicPath(publicPath: string): string | null {
return resolvedPath;
}
export default defineConfig({
plugins: [
react(),
saveMapPlugin(),
saveSrtPlugin(),
saveDialogueManifestPlugin(),
saveCinematicManifestPlugin(),
validateDialoguesPlugin(),
],
resolve: {
alias: {
"@": fileURLToPath(new URL("./src", import.meta.url)),
export default defineConfig(({ mode }) => {
const isThreeDebug = mode === "three-debug";
return {
plugins: [
react(),
saveMapPlugin(),
saveSrtPlugin(),
saveDialogueManifestPlugin(),
saveCinematicManifestPlugin(),
validateDialoguesPlugin(),
],
resolve: {
alias: [
{
find: "@",
replacement: fileURLToPath(new URL("./src", import.meta.url)),
},
...(isThreeDebug
? [{ find: /^three$/, replacement: THREE_SOURCE_ENTRY }]
: []),
],
},
},
...(isThreeDebug
? {
optimizeDeps: {
exclude: ["three"],
},
}
: {}),
};
});