Skip to content

Commit c447cb5

Browse files
Add Base64Url encoding (#56)
* Add Base64Url encoding
1 parent e3fd539 commit c447cb5

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

CHANGELOG.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ New features:
5656
- `INSPECT_MAX_BYTES`: https://nodejs.org/docs/latest-v18.x/api/buffer.html#bufferinspect_max_bytes
5757
- `MAX_LENGTH`: https://nodejs.org/docs/latest-v18.x/api/buffer.html#bufferconstantsmax_length
5858
- `MAX_STRING_LENGTH`: https://nodejs.org/docs/latest-v18.x/api/buffer.html#bufferconstantsmax_string_length
59-
59+
- Added a new data constructor for `Encoding`: `Base64Url` (#56 by @JordanMartinez)
6060

6161
Bugfixes:
6262

src/Node/Encoding.purs

+3
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ data Encoding
1414
| UTF16LE
1515
| UCS2
1616
| Base64
17+
| Base64Url
1718
| Latin1
1819
| Binary
1920
| Hex
@@ -24,6 +25,7 @@ instance showEncoding :: Show Encoding where
2425
show UTF16LE = "UTF16LE"
2526
show UCS2 = "UCS2"
2627
show Base64 = "Base64"
28+
show Base64Url = "Base64Url"
2729
show Latin1 = "Latin1"
2830
show Binary = "Binary"
2931
show Hex = "Hex"
@@ -36,6 +38,7 @@ encodingToNode UTF8 = "utf8"
3638
encodingToNode UTF16LE = "utf16le"
3739
encodingToNode UCS2 = "ucs2"
3840
encodingToNode Base64 = "base64"
41+
encodingToNode Base64Url = "base64url"
3942
encodingToNode Latin1 = "latin1"
4043
encodingToNode Binary = "binary"
4144
encodingToNode Hex = "hex"

0 commit comments

Comments
 (0)