Comments (1)
@samaxes i have running it on the latest Angular 4.4.4
This issue is not about angular version, it's about AoT compile mode.
AoT requires factory functions and constants to be exported
Please, try this:
`
export function appInit(i18next: ITranslationService) {
return () => i18next.init();
}
export function localeIdFactory(i18next: ITranslationService) {
return i18next.language;
}
export const I18N_PROVIDERS = [
{
provide: APP_INITIALIZER,
useFactory: appInit,
deps: [I18NEXT_SERVICE],
multi: true
},
{
provide: LOCALE_ID,
deps: [I18NEXT_SERVICE],
useFactory: localeIdFactory
}];
`
Please, let me know, if it has been resolved your issue.
from angular-i18next.
Related Issues (20)
- Is it possible to publish the 15.0 pre-release version to npm? HOT 2
- Interpolation is not working anymore HOT 4
- Property 'initialized' in type 'I18NextEvents' is not assignable to the same property in base type 'ITranslationEvents'. HOT 4
- Is it possible to use this library with Angular Universal and SSR? HOT 4
- New typings prevents passing interpolation to `ITranslationService` HOT 1
- Interpolation Format issues with numbers / dates or i18nextCap HOT 2
- Integration to Angular 16 HOT 9
- angular version issue HOT 1
- Check if there is a translation for the specified key HOT 1
- Update to last i18next version HOT 3
- Mock angular-i18next in Jest HOT 2
- Error when building project in docker HOT 3
- Nesting example HOT 1
- Consider providing a `ng add` schematics HOT 1
- i18next::translator: missingKey on simple implementation HOT 1
- Unit test run error HOT 3
- Change Language without reloading page HOT 2
- Build error when updating to 14.2.0 with strict typing HOT 24
- Getting started with Angular v15 HOT 4
- Support i18next v22 HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from angular-i18next.