Closed MickL closed 3 years ago
Hi @MickL , thanks for reporting.
Use DateFnsModule
in lazy loaded modules, DateFnsModule.forRoot()
only in the root module.
I added an example in the demo app and a note in the readme. Details here: https://github.com/joanllenas/ngx-date-fns/commit/1bfe54fd232e39b34e48bbe43a99dea3782d8593
Hope this clarifies your issue!
When having lazy loaded modules:
Should AppModule import with
forRoot()
and all others without? Or should all 3 import with forRoot?Maybe would be nice if you could add this information to the docs, too :)