Skip to content

Commit 99e66d0

Browse files
committed
-> v4.3.0
1 parent 13e9f65 commit 99e66d0

File tree

3 files changed

+8
-3
lines changed

3 files changed

+8
-3
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# devalue changelog
22

3+
## 4.3.0
4+
5+
- Support custom types ([#58](https://github.com/Rich-Harris/devalue/pull/58))
6+
37
## 4.2.3
48

59
- Correctly escape control characters ([#57](https://github.com/Rich-Harris/devalue/pull/57))

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ Like `JSON.stringify`, but handles
99
- dates
1010
- `Map` and `Set`
1111
- `BigInt`
12+
- custom types via replacers, reducers and revivers
1213

1314
Try it out [here](https://svelte.dev/repl/138d70def7a748ce9eda736ef1c71239?version=3.49.0).
1415

@@ -21,7 +22,7 @@ Try it out [here](https://svelte.dev/repl/138d70def7a748ce9eda736ef1c71239?versi
2122
## Non-goals:
2223

2324
- Human-readable output
24-
- Stringifying functions or non-POJOs
25+
- Stringifying functions
2526

2627
## Usage
2728

@@ -123,7 +124,7 @@ Note that any variables referenced in the resulting JavaScript (like `Vector` in
123124

124125
## Error handling
125126

126-
If `uneval` or `stringify` encounters a function or a non-POJO, it will throw an error. You can find where in the input data the offending value lives by inspecting `error.path`:
127+
If `uneval` or `stringify` encounters a function or a non-POJO that isn't handled by a custom replacer/reducer, it will throw an error. You can find where in the input data the offending value lives by inspecting `error.path`:
127128

128129
```js
129130
try {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "devalue",
33
"description": "Gets the job done when JSON.stringify can't",
4-
"version": "4.2.3",
4+
"version": "4.3.0",
55
"repository": "Rich-Harris/devalue",
66
"exports": {
77
".": {

0 commit comments

Comments
 (0)