Closed benwilber closed 3 months ago
The T separator is just convention. It can be any single character.
T
https://github.com/Urigo/graphql-scalars/blob/master/src/scalars/iso-date/formatter.ts#L21
Parsing milliseconds with this regex is not allowing comma , separator, only dot .
,
.
https://github.com/Urigo/graphql-scalars/blob/master/src/scalars/iso-date/formatter.ts#L49
It also doesn't appear to handle 2-digit timezones. ie +00 instead of +0000
+00
+0000
Postgres default timestamptz formatter returns strings like 2024-04-01 01:00:00,000+00
timestamptz
2024-04-01 01:00:00,000+00
So this library will fail to parse that in at least 3 different ways, even though it's perfectly valid ISO-8601 format.
The
T
separator is just convention. It can be any single character.https://github.com/Urigo/graphql-scalars/blob/master/src/scalars/iso-date/formatter.ts#L21
Parsing milliseconds with this regex is not allowing comma
,
separator, only dot.
https://github.com/Urigo/graphql-scalars/blob/master/src/scalars/iso-date/formatter.ts#L49
It also doesn't appear to handle 2-digit timezones. ie
+00
instead of+0000
Postgres default
timestamptz
formatter returns strings like2024-04-01 01:00:00,000+00
So this library will fail to parse that in at least 3 different ways, even though it's perfectly valid ISO-8601 format.