From 0c0a88a02e934f560ee894d73137738db59a81b8 Mon Sep 17 00:00:00 2001 From: Julien Gautier Date: Tue, 12 May 2026 00:26:52 +0200 Subject: [PATCH] =?UTF-8?q?feat(portal-shell):=20ci=20gate=20=E2=80=94=20f?= =?UTF-8?q?ail=20prod=20build=20on=20missing=20translations?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Set `i18nMissingTranslation: "error"` on the production build configuration. The Angular CLI checks every `` extracted from `i18n` markers and `$localize` calls against the loaded translation file (`messages.fr.xlf`), and now fails the build if a target is missing instead of silently falling back to the source text in the FR bundle. Gates automatically through CI: `pnpm ci:check` runs `nx affected -t ... build`, which uses the production configuration by default. A PR that adds an `i18n` marker without updating `messages.fr.xlf` fails its build job and blocks the merge. Verified locally by temporarily inserting an unmarked-in-fr string, running the prod build, observing the explicit error message: ERROR: No translation found for "sanity.test.missingTranslation" ("A string with no FR translation"). Closes the loop on ADR-0019 §"Confirmation" — the final piece of the i18n track before the BFF route + cookie work (deferred to the auth-flow chantier). --- apps/portal-shell/project.json | 1 + 1 file changed, 1 insertion(+) diff --git a/apps/portal-shell/project.json b/apps/portal-shell/project.json index 9868da0..70eab48 100644 --- a/apps/portal-shell/project.json +++ b/apps/portal-shell/project.json @@ -38,6 +38,7 @@ "configurations": { "production": { "localize": ["en", "fr"], + "i18nMissingTranslation": "error", "budgets": [ { "type": "initial",