Angular Translations: Build vs. Runtime
dev.to·9h·
Discuss: DEV
🎮Language Ergonomics
Preview
Report Post

Implementing internationalization (i18n) in Angular is a pivotal decision for any scaling application. However, the choice often feels like a tug-of-war between performance and flexibility.

In this article, we’ll break down the two primary schools of thought in Angular translation—Build-time vs. Runtime—and introduce a tool that bridges the gap for modern development teams: UI Translator.

1. The Build-time Approach (@angular/localize)

Let’s first talk about the "Official" Angular way. This method involves marking text in your templates with the i18n attribute(the internationalization of your code), then using the Angular dedicated command ng extract-i18n to extract all the marked messages into the so-called source translation file t…

Similar Posts

Loading similar posts...

Keyboard Shortcuts

Navigation
Next / previous item
j/k
Open post
oorEnter
Preview post
v
Post Actions
Love post
a
Like post
l
Dislike post
d
Undo reaction
u
Recommendations
Add interest / feed
Enter
Not interested
x
Go to
Home
gh
Interests
gi
Feeds
gf
Likes
gl
History
gy
Changelog
gc
Settings
gs
Browse
gb
Search
/
General
Show this help
?
Submit feedback
!
Close modal / unfocus
Esc

Press ? anytime to show this help