i18n angular
content_copy
ng xi18n --output-path src/locale
content_copy
function plural(n: number): number {
let i = Math.floor(Math.abs(n)), v = n.toString().replace(/^[^.]*\.?/, '').length;
if (i === 1 && v === 0) return 1;
return 5;
}
content_copy
<span i18n>Updated: {minutes, plural,
=0 {just now}
=1 {one minute ago}
other {{{minutes}} minutes ago by {gender, select, male {male} female {female} other {other}}}}
</span>
content_copy
ng xi18n --out-file source.xlf
content_copy
ng xi18n --format=xlf
ng xi18n --format=xlf2
ng xi18n --format=xmb
Also in JavaScript:
- alert user javascript
- News Application With Angular and Material Design
- pass header in ajax
- how to convert array converted to string back to array javasccript
- jquery continue in loop each
- html button click only once
- what is pug template engine
- get random numbers javascript
- How to make a timer in javascript
- event listener javascript
- jquery selected label option
- flutter local json storage
- how to get a channelid discord.js
- vuejs my chart load before fetch data
- document ready js
- javascript json trypass
- javascript const
- expressjs cheat sheet
- how to lazyload angular
- javascript define global variable
- flutter reorder map by key
- js variable to string
- data type angular
- js if tab is active