-
-
Notifications
You must be signed in to change notification settings - Fork 15
Integration
alexcibotari edited this page Feb 26, 2023
·
5 revisions
You will need to know your Firebase project ID, Space ID and host domain name.
Hosting domain names:
<firebase-project-id>.web.app
<firebase-project-id>.firebaseapp.com
custom domain name
To integrate with any framework you will need only to know the locale url. Every framework will allow you to configure url where your dictionary is located.
https://<host-domain-name>/api/v1/spaces/<space-id>/translations/<locale>
Checkout @lessify/angular-tools to synchronize or export local and Localess translations.
Detailed guid you can find on official Transloco site
@Injectable({ providedIn: 'root' })
export class TranslocoHttpLoader implements TranslocoLoader {
constructor(private readonly http: HttpClient) {}
getTranslation(lang: string): Observable<Translation> {
return this.http.get<Translation>(`https://<host-domain-name>/api/v1/spaces/<space-id>/translations/${lang}`);
}
}