File tree Expand file tree Collapse file tree 1 file changed +1
-1
lines changed Expand file tree Collapse file tree 1 file changed +1
-1
lines changed Original file line number Diff line number Diff line change @@ -314,7 +314,7 @@ type ApiEndpoint = `/api/${ApiRoute}`; // Type ApiEndpoint = "/api/users" | "/ap
314314const userEndpoint: ApiEndpoint = ' /api/users' ;
315315
316316// ❌ Avoid
317- const homeTitle = ' translation.homesss.title' ; // Type 'string' - Since typo 'homesss', translation doesn't exist and results in runtime error
317+ const homeTitle = ' translation.homesss.title' ; // Type 'string' - Typo 'homesss': the translation doesn't exist, leading to a runtime error.
318318// ✅ Use
319319type LocaleKeyPages = ' home' | ' about' | ' contact' ;
320320type TranslationKey = ` translation.${LocaleKeyPages }.${string } ` ; // Type TranslationKey = `translation.home.${string}` | `translation.about.${string}` | `translation.contact.${string}`
You can’t perform that action at this time.
0 commit comments