2016-09-09 00:41:09 -04:00
|
|
|
/**
|
|
|
|
* @license
|
2020-05-19 15:08:49 -04:00
|
|
|
* Copyright Google LLC All Rights Reserved.
|
2016-09-09 00:41:09 -04:00
|
|
|
*
|
|
|
|
* Use of this source code is governed by an MIT-style license that can be
|
|
|
|
* found in the LICENSE file at https://angular.io/license
|
|
|
|
*/
|
|
|
|
|
|
|
|
import {Component, NgModule} from '@angular/core';
|
|
|
|
import {BrowserModule} from '@angular/platform-browser';
|
|
|
|
|
|
|
|
import {AsyncObservablePipeComponent, AsyncPromisePipeComponent} from './async_pipe';
|
2021-01-19 05:32:30 -05:00
|
|
|
import {CurrencyPipeComponent} from './currency_pipe';
|
2017-08-29 14:10:58 -04:00
|
|
|
import {DatePipeComponent, DeprecatedDatePipeComponent} from './date_pipe';
|
2016-09-09 00:41:09 -04:00
|
|
|
import {I18nPluralPipeComponent, I18nSelectPipeComponent} from './i18n_pipe';
|
|
|
|
import {JsonPipeComponent} from './json_pipe';
|
2018-06-06 05:31:22 -04:00
|
|
|
import {KeyValuePipeComponent} from './keyvalue_pipe';
|
2016-09-09 00:41:09 -04:00
|
|
|
import {LowerUpperPipeComponent} from './lowerupper_pipe';
|
2021-01-19 05:32:30 -05:00
|
|
|
import {NumberPipeComponent} from './number_pipe';
|
|
|
|
import {PercentPipeComponent} from './percent_pipe';
|
2016-09-09 00:41:09 -04:00
|
|
|
import {SlicePipeListComponent, SlicePipeStringComponent} from './slice_pipe';
|
2018-03-13 22:46:10 -04:00
|
|
|
import {TitleCasePipeComponent} from './titlecase_pipe';
|
2016-09-09 00:41:09 -04:00
|
|
|
|
|
|
|
@Component({
|
|
|
|
selector: 'example-app',
|
|
|
|
template: `
|
|
|
|
<h1>Pipe Example</h1>
|
|
|
|
|
|
|
|
<h2><code>async</code></h2>
|
|
|
|
<async-promise-pipe></async-promise-pipe>
|
|
|
|
<async-observable-pipe></async-observable-pipe>
|
|
|
|
|
|
|
|
<h2><code>date</code></h2>
|
|
|
|
<date-pipe></date-pipe>
|
2018-06-06 05:31:22 -04:00
|
|
|
|
2016-09-09 00:41:09 -04:00
|
|
|
<h2><code>json</code></h2>
|
|
|
|
<json-pipe></json-pipe>
|
|
|
|
|
|
|
|
<h2><code>lower</code>, <code>upper</code></h2>
|
|
|
|
<lowerupper-pipe></lowerupper-pipe>
|
|
|
|
|
2018-03-13 22:46:10 -04:00
|
|
|
<h2><code>titlecase</code></h2>
|
|
|
|
<titlecase-pipe></titlecase-pipe>
|
|
|
|
|
2016-09-09 00:41:09 -04:00
|
|
|
<h2><code>number</code></h2>
|
|
|
|
<number-pipe></number-pipe>
|
|
|
|
<percent-pipe></percent-pipe>
|
|
|
|
<currency-pipe></currency-pipe>
|
|
|
|
|
|
|
|
<h2><code>slice</code></h2>
|
|
|
|
<slice-string-pipe></slice-string-pipe>
|
|
|
|
<slice-list-pipe></slice-list-pipe>
|
|
|
|
|
|
|
|
<h2><code>i18n</code></h2>
|
|
|
|
<i18n-plural-pipe></i18n-plural-pipe>
|
|
|
|
<i18n-select-pipe></i18n-select-pipe>
|
2018-06-06 05:31:22 -04:00
|
|
|
|
|
|
|
<h2><code>keyvalue</code></h2>
|
|
|
|
<keyvalue-pipe></keyvalue-pipe>
|
2016-09-09 00:41:09 -04:00
|
|
|
`
|
|
|
|
})
|
2019-01-28 15:59:25 -05:00
|
|
|
export class AppComponent {
|
2016-09-09 00:41:09 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
@NgModule({
|
|
|
|
declarations: [
|
2019-01-28 15:59:25 -05:00
|
|
|
AsyncPromisePipeComponent, AsyncObservablePipeComponent, AppComponent, JsonPipeComponent,
|
2018-03-13 22:46:10 -04:00
|
|
|
DatePipeComponent, DeprecatedDatePipeComponent, LowerUpperPipeComponent, TitleCasePipeComponent,
|
2021-01-19 05:32:30 -05:00
|
|
|
NumberPipeComponent, PercentPipeComponent, CurrencyPipeComponent, SlicePipeStringComponent,
|
|
|
|
SlicePipeListComponent, I18nPluralPipeComponent, I18nSelectPipeComponent, KeyValuePipeComponent
|
2016-09-09 00:41:09 -04:00
|
|
|
],
|
|
|
|
imports: [BrowserModule],
|
|
|
|
})
|
|
|
|
export class AppModule {
|
|
|
|
}
|