mirror of
https://github.com/Tzahi12345/YoutubeDL-Material.git
synced 2026-04-04 17:41:27 +03:00
Removed @locl dependency for translations
Added CommonModule to fix intellisense Added ability to load json assets by name, and an http call to update youtubedl-material
This commit is contained in:
@@ -6,7 +6,6 @@ import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
|
||||
import { environment } from './environments/environment';
|
||||
|
||||
import { loadTranslations } from '@angular/localize';
|
||||
import { getTranslations, ParsedTranslationBundle } from '@locl/core';
|
||||
|
||||
if (environment.production) {
|
||||
enableProdMode();
|
||||
@@ -17,8 +16,7 @@ if (!locale) {
|
||||
localStorage.setItem('locale', 'en');
|
||||
}
|
||||
if (locale && locale !== 'en') {
|
||||
getTranslations(`./assets/i18n/messages.${locale}.json`).then(
|
||||
(data: ParsedTranslationBundle) => {
|
||||
fetch(`./assets/i18n/messages.${locale}.json`).then(res => res.json()).then((data) => {
|
||||
loadTranslations(data as any);
|
||||
import('./app/app.module').then(module => {
|
||||
platformBrowserDynamic()
|
||||
|
||||
Reference in New Issue
Block a user