Skip to content

Conversation

@flymans
Copy link
Contributor

@flymans flymans commented Aug 20, 2021

allow users to strictly validate dates with "." as delimiter.

Closes #1709

Checklist

  • PR contains only changes related; no stray files, etc.
  • README updated (where applicable)
  • Tests written (where applicable)

@codecov
Copy link

codecov bot commented Aug 20, 2021

Codecov Report

Merging #1711 (6e3c9f3) into master (8c4b3b3) will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##            master     #1711   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          101       101           
  Lines         2005      2005           
  Branches       452       452           
=========================================
  Hits          2005      2005           
Impacted Files Coverage Δ
src/lib/isDate.js 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8c4b3b3...6e3c9f3. Read the comment docs.

Copy link
Member

@tux-tn tux-tn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your PR @flymans
LGTM 🎉
isDate documentation is ambiguous, we should probably state that delimiters array can only include / . or - or may be refactor the validator in a way we can pass any delimiter as an option. I will probably open an issue to discuss it cc @profnandaa

@tux-tn tux-tn added 🎉 first-pr ready-to-land For PRs that are reviewed and ready to be landed labels Sep 25, 2021
Copy link
Member

@profnandaa profnandaa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for your contrib! 🎉

@profnandaa profnandaa merged commit b0d49bd into validatorjs:master Sep 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🎉 first-pr ready-to-land For PRs that are reviewed and ready to be landed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

isDate(): Format 'DD.MM.YYYY' does not pass isValidFormat

3 participants