Skip to content

Commit

Permalink
fix(ai-help): avoid plainHTML for other locales (#10206)
Browse files Browse the repository at this point in the history
  • Loading branch information
caugner authored Dec 19, 2023
1 parent 23b78d9 commit fa38994
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions build/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import {
BUILD_OUT_ROOT,
SENTRY_DSN_BUILD,
} from "../libs/env/index.js";
import { VALID_LOCALES } from "../libs/constants/index.js";
import { DEFAULT_LOCALE, VALID_LOCALES } from "../libs/constants/index.js";
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore
import { renderHTML } from "../ssr/dist/main.js";
Expand Down Expand Up @@ -79,7 +79,9 @@ async function buildDocumentInteractive(

return {
document,
doc: await buildDocument(document, { plainHTML: true }),
doc: await buildDocument(document, {
plainHTML: document.metadata.locale === DEFAULT_LOCALE,
}),
skip: false,
};
} catch (e) {
Expand Down

0 comments on commit fa38994

Please sign in to comment.