Hello I have problem validating and confirming date format of given date.
Admin enters valid date format for input and user enters date in input.
For example: User enters 2020-05-10
and admin has entered Y-m-d
my validation function must return true
Both inputs are dynamic and I don't have idea how to confirm format
I saw this solution but this is not dynamic: Check date format in JavaScript
Any help will be apreciated