Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Handle valid date provided as string danrevah#224
It is common use-case to provide date as a valid string. Even the backend responses come as a plain string which represents the date.
- Loading branch information
682a87a
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're still treating the input string as a Date in the if clause. Would it not be better to check for 'undefined' or Invalid Date and then use the parsed value further down.