Skip to content

Instantly share code, notes, and snippets.

@kutanov
Created April 17, 2020 09:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kutanov/a9691f2e3e9618a8e3da13d4ab69f289 to your computer and use it in GitHub Desktop.
Save kutanov/a9691f2e3e9618a8e3da13d4ab69f289 to your computer and use it in GitHub Desktop.
@Component({
selector: 'app-comp',
templateUrl: './app-comp.component.html',
providers: [
{
provide: TRANSLOCO_LOADING_TEMPLATE,
useValue: '<p>Translation is loading...</p>'
}
]
})
export class AppComp {}
<ng-container *transloco="let t; loadingTpl: loading">
<h1>{{ t('title') }}</h1>
</ng-container>
<ng-template #loading>
<h1>Loading...</h1>
</ng-template>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment