Closed waveiron closed 3 years ago
Hi @waveiron , Not accepting invalid input values was a decision I made when I started this project, but at this point, I agree that this is not what you expect from a pipe.
I will probably follow a pattern similar to what Angular uses for its pipes: https://github.com/angular/angular/blob/11.0.3/packages/common/src/pipes/number_pipe.ts#L239
Does that work for you?
For consistency sake, I will apply the same fix to other pipes where it makes sense to do it.
@joanllenas That will work, since pipes accept "loose" data in view level. Thanks for your great work.
Hi @waveiron Just released v7 with your suggestion implemented: https://github.com/joanllenas/ngx-date-fns/releases/tag/v7.0.0 Cheers!
@joanllenas Wow, thanks for your great work!
Description of the Issue and Steps to Reproduce:
Did you search for duplicate issue? [Yes]
Please describe the issue and steps to reproduce, preferably with a code sample / plunker:
This will throw: