t function exported
Last updated: 2026-03-01T23:25:47.122Z
Location
Metrics
LOC: 7
Complexity: 4
Params: 2
Signature
t(key: string, substitutions?: string | string[]): : string
Summary
Returns the localized message for the given key. Falls back to the key itself if the message is not found (useful during development).
Source Code
export function t(key: string, substitutions?: string | string[]): string {
if (_catalog) {
const resolved = resolveFromCatalog(key, substitutions);
if (resolved !== null) return resolved;
}
return chrome.i18n.getMessage(key, substitutions) || key;
}
Dependencies (Outgoing)
| Target | Type |
|---|---|
| resolveFromCatalog | calls |
No incoming dependencies.