REGEX ISO DATE

Open Beginner friendly
#327 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
61/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Stale
Tech stack
angularjs, javascript
Domain
frontend

Research direction

Locate the isISODateString function and inspect the regex used during the initial load of the date field. Compare its behavior with the regex in the issue, then verify that valid ISO dates are formatted correctly when the field loads.

Written by the indexing model from the issue text.

Description

o regex da função isISODateString esta incorreto causando a não formatação correta da data no load inicial do campo, segue regex correto

/^(?:[1-9]\d{3}-(?:(?:0[1-9]|1[0-2])-(?:0[1-9]|1\d|2[0-8])|(?:0[13-9]|1[0-2])-(?:29|30)|(?:0[13578]|1[02])-31)|(?:[1-9]\d(?:0[48]|[2468][048]|[13579][26])|(?:[2468][048]|[13579][26])00)-02-29)T(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:Z|[+-][01]\d:[0-5]\d)$/

Dominant language
JavaScript
Stars
955
Forks
329
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from assisrafael/angular-input-masks

All issues in assisrafael/angular-input-masks

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.