Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
ember-intl
Advanced tools
"in 1 day"
, "2 years ago"
, etc.Intl.PluralRules
API'
instead of a slash \
Intl.RelativeTime
polyfill has been replaced with the native API which behaves entirely different than the previous older spec implementation (read about in the Migration Document)intl.lookup()
API will no longer return missing translation warningsshortNumber
formatting in favor of now supported native implementation using the "notation"
property i.e.,this.intl.formatNumber(1000, {
notation: "compact" ,
compactDisplay: "short"
}); // -> 1k
All of this will result in smaller bundles, faster build times, and less work done on app boot.
When you're ready to upgrade, head over to the Migration Document to read more in detail about what changed.
Support for TypeScript has been added in v5.5.0
. If you have any custom types,
you can remove them now. When injecting the intl
service, type it like so:
import Component from '@glimmer/component';
import type IntlService from 'ember-intl/services/intl';
export default class ExampleComponent extends Component {
@service intl!: IntlService;
}
You may encounter seemingly unrelated type errors when updating to
ember-intl@^5.5.0
, like:
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(555,58): error TS2339: Property 'flat' does not exist on type 'any[]'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(556,61): error TS2339: Property 'flatMap' does not exist on type 'any[]'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(597,57): error TS2339: Property 'flat' does not exist on type 'any[]'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(598,60): error TS2339: Property 'flatMap' does not exist on type 'any[]'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(949,47): error TS2339: Property 'fromEntries' does not exist on type 'ObjectConstructor'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(965,48): error TS2339: Property 'allSettled' does not exist on type 'PromiseConstructor'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(1064,64): error TS2339: Property 'matchAll' does not exist on type 'String'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(1082,65): error TS2339: Property 'trimStart' does not exist on type 'String'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(1084,63): error TS2339: Property 'trimEnd' does not exist on type 'String'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(1115,63): error TS2339: Property 'matchAll' does not exist on type 'String'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(1133,64): error TS2339: Property 'trimStart' does not exist on type 'String'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(1135,62): error TS2339: Property 'trimEnd' does not exist on type 'String'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(1145,94): error TS2339: Property 'description' does not exist on type 'Symbol'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(1153,44): error TS2339: Property 'matchAll' does not exist on type 'SymbolConstructor'.
./node_modules/@types/es-abstract/GetIntrinsic.d.ts(1163,93): error TS2339: Property 'description' does not exist on type 'Symbol'.
You can fix these by adding ES2020
to your compilerOptions.lib
or setting
the compilerOptions.target
to ES2020
in tsconfig.json
.
See #1426 for more details.
There's an ember-i18n-to-intl-migrator tool that is used to convert your translations files and application code to ember-intl.
If you have any questions or issues, please open in ember-i18n-to-intl-migrator/issues
FAQs
Internationalization for Ember projects
The npm package ember-intl receives a total of 34,213 weekly downloads. As such, ember-intl popularity was classified as popular.
We found that ember-intl demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.