An invalid creationDate fails with a bare RangeError
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 82/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- angular, typescript
- Domain
- backend-api-design, documentation
Research direction
Start with the validation in engine/index.ts around line 218, then read rendering-api.md to follow how the existing language and pageMode errors are documented. The issue reports failing tests for invalid dates; use those cases to check the behavior. Done means an invalid creationDate throws ngpdf: invalid creationDate and the error is listed in the docs.
Written by the indexing model from the issue text.
Description
[creationDate]="new Date(row.generatedAt)" with a missing or bad value rejects with Invalid time value, with no ngpdf: prefix and no hint of what caused it.
engine/index.ts:218 accepts an Invalid Date, because it only tests date instanceof Date.
@ngpdf/core 1.0.1. Each case was reproduced with a failing test.
Expected
An ngpdf: error naming creationDate. rendering-api.md: "Errors from ngpdf start with ngpdf:". language and pageMode are already checked.
Done when
- An Invalid Date throws
ngpdf: invalid creationDate. - It is listed with the other errors in
rendering-api.md.
- Dominant language
- TypeScript
- Stars
- 1
- Forks
- 0
- Avg merge
- 8h 9m
- Merged PRs (30d)
- 129
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from ngpdf/ngpdf
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
Similar issues
-
area: web
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
inabagumi/shinju-date#6823 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
vercel-labs/ui#540 ·
Maintainers usually reply within 1 day
-
accepted ai-dev ai-implementing
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
livesport/homer#218 · 1 comment ·
Maintainers usually reply within 1 day
-
normalizePropName strips `#` characters from Figma property names instead of only the `#id` suffixOpen
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
figma/code-connect#419 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100