Taula de continguts

angular: pipes

uppercase, lowercase

slice (5.2)

decimal (5.3)

percent

currency

cambiar fecha (locale) a castellana

Configuración necesaria en el fichero app.module.ts

import { BrowserModule } from '@angular/platform-browser';
import { LOCALE_ID, NgModule } from '@angular/core';
 
import { AppComponent } from '../src/app/app.component';
 
import localeEs from '@angular/common/locales/es';
import { registerLocaleData } from '@angular/common';
registerLocaleData(localeEs);
 
@NgModule({
 imports: [ BrowserModule ],
 declarations: [ AppComponent ],
 providers: [ { provide: LOCALE_ID, useValue: 'es' } ],
 bootstrap: [ AppComponent ]
})
export class AppModule { }

json (5.4)

async

creando nuestro pipe

ng g[enerate] pipe <DIRECTORIO>/<NOMBRE>
1)
Cross-Site Scripting