I would like to change the language of the date of my app so that it is from Argentina, I tried with this configuration seeing the angular documentation but it still does not change. The default setting is en-US. It does not show me any error by console
app.module.ts
import { registerLocaleData } from '@angular/common';
import localeEsAr from '@angular/common/locales/es-AR';
registerLocaleData(localeEsAr);
app.component.html
<td>{{resultado.date?.seconds * 1000| date:'fullDate'}}</td>
What you are missing is to import the locales from angular common locales, also register them so you can use them, that should fix your error
and if you keep getting the same error, check your locales folder if it contains es-Ar, in your case you should only import es-Ar, in my example it shows several other locales
The problem is how you are setting the localization. From the official documentation, this is what goes into
app.module.ts
:The method that you use to register the locale, I understand that it is useful if you are going to use multiple locations and not just one.
In that case, you would have to indicate which locale you are going to use in the pipe.