From ce22ca07fffc890191893405790b6e49b9de724a Mon Sep 17 00:00:00 2001 From: "Sakamoto, Kazunori" Date: Sun, 13 Sep 2026 21:41:59 +0900 Subject: [PATCH] perf: defer HTML formatter imports for browser graders Co-authored-by: WillBooster (Codex CLI) --- packages/problem-utils-browser/src/html.ts | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/packages/problem-utils-browser/src/html.ts b/packages/problem-utils-browser/src/html.ts index 25e0a99..0214f99 100644 --- a/packages/problem-utils-browser/src/html.ts +++ b/packages/problem-utils-browser/src/html.ts @@ -10,10 +10,7 @@ import { startLocalHttpServer, type TestCaseResult, } from '@exercode/problem-utils'; -import sniffHtmlEncoding from 'html-encoding-sniffer'; import type { Page } from 'puppeteer'; -import { format } from 'prettier'; -import prettierPluginOrganizeAttributes from 'prettier-plugin-organize-attributes'; import { createBrowserPage, capturePngScreenshot, launchBrowser } from './browser.js'; import { createTemporaryDirectory } from './temporaryDirectory.js'; @@ -258,6 +255,12 @@ async function loadFormattedHtmlForScreenshot(url: string): Promise