From e9a8fa2cea8d8a1c4aed5b83dfcd8772b62cd462 Mon Sep 17 00:00:00 2001 From: hided62 Date: Fri, 21 Aug 2026 01:08:39 +0000 Subject: [PATCH] =?UTF-8?q?perf:=20=EB=82=B4=20=EC=A0=95=EB=B3=B4=20?= =?UTF-8?q?=ED=99=94=EB=A9=B4=EC=9D=98=20=EB=A1=9C=EC=A7=81=20=EB=B0=B0?= =?UTF-8?q?=EB=9F=B4=20=EB=A1=9C=EB=94=A9=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/game-frontend/src/views/MyPageView.vue | 2 +- app/game-frontend/test/routerLoading.test.ts | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/app/game-frontend/src/views/MyPageView.vue b/app/game-frontend/src/views/MyPageView.vue index 28d367d7..61b037a6 100644 --- a/app/game-frontend/src/views/MyPageView.vue +++ b/app/game-frontend/src/views/MyPageView.vue @@ -3,7 +3,7 @@ import { computed, onMounted, reactive, ref, watch } from 'vue'; import { trpc } from '../utils/trpc'; import { formatLog } from '../utils/formatLog'; import { formatSeoulDateTime } from '../utils/legacyDateTime'; -import { isDefenceTrainPenaltyWaivedByScenarioEffect } from '@sammo-ts/logic'; +import { isDefenceTrainPenaltyWaivedByScenarioEffect } from '@sammo-ts/logic/scenario/scenarioEffect.js'; import { useSessionStore } from '../stores/session'; import { resolveGeneralIconUrl, useDefaultGeneralIcon } from '../utils/generalIcon'; import LegacyGeneralProgress from '../components/ui/LegacyGeneralProgress.vue'; diff --git a/app/game-frontend/test/routerLoading.test.ts b/app/game-frontend/test/routerLoading.test.ts index e7eb4d23..f3a789e9 100644 --- a/app/game-frontend/test/routerLoading.test.ts +++ b/app/game-frontend/test/routerLoading.test.ts @@ -5,6 +5,7 @@ import { describe, it } from 'node:test'; const routerSourcePath = path.resolve(import.meta.dirname, '../src/router/index.ts'); const mainDashboardSourcePath = path.resolve(import.meta.dirname, '../src/stores/mainDashboard.ts'); +const myPageSourcePath = path.resolve(import.meta.dirname, '../src/views/MyPageView.vue'); void describe('game route loading contract', () => { void it('loads view components through route-level dynamic imports', async () => { @@ -26,4 +27,11 @@ void describe('game route loading contract', () => { assert.doesNotMatch(source, /from\s+['"]@sammo-ts\/logic['"]/); assert.match(source, /from\s+['"]@sammo-ts\/logic\/messages\/message\.js['"]/); }); + + void it('does not preload the server-side logic barrel from the my-page route', async () => { + const source = await readFile(myPageSourcePath, 'utf8'); + + assert.doesNotMatch(source, /from\s+['"]@sammo-ts\/logic['"]/); + assert.match(source, /from\s+['"]@sammo-ts\/logic\/scenario\/scenarioEffect\.js['"]/); + }); });