1 | # Changelog
|
2 |
|
3 | > **Tags:**
|
4 | >
|
5 | > - [New Feature]
|
6 | > - [Bug Fix]
|
7 | > - [Breaking Change]
|
8 | > - [Documentation]
|
9 | > - [Internal]
|
10 | > - [Polish]
|
11 | > - [Experimental]
|
12 | > - [Deprecation]
|
13 |
|
14 | **Note**: Gaps between patch versions are faulty/broken releases.
|
15 | **Note**: A feature tagged as Experimental is in a high state of flux, you're at risk of it changing without notice.
|
16 |
|
17 | # 2.2.5
|
18 |
|
19 | - **Experimental**
|
20 | - fix type information lost from nested decoder types, #479 (@gcanti)
|
21 | - `JsonEncoder`
|
22 | - change `id` signature (@gcanti)
|
23 |
|
24 | # 2.2.4
|
25 |
|
26 | - **Polish**
|
27 | - remove the dependency on the `either` instance as a mean of improving tree shaking (@gcanti)
|
28 |
|
29 | # 2.2.3
|
30 |
|
31 | - **Polish**
|
32 | - use the built-in `Readonly` type in `readonly` combinator, closes #472 (@gcanti)
|
33 | - **Experimental**
|
34 | - split instances (@gcanti)
|
35 | - add `Type` experimental module, #464 (@gcanti)
|
36 | - restore the `O` type parameter to `Encoder`, #469 (@gcanti)
|
37 | - add the `O` type parameter to `Codec` (@gcanti)
|
38 | - add `JsonCodec` experimental module (@gcanti)
|
39 | - add `JsonEncoder` experimental module (@gcanti)
|
40 | - `Schemable`
|
41 | - rename `Schemable` interface to `Schemable1` (@gcanti)
|
42 | - rename `WithUnion` interface to `WithUnion1` (@gcanti)
|
43 | - add `Schemable` interface (@gcanti)
|
44 | - add `WithUnion` interface (@gcanti)
|
45 | - add `WithRefinement` / `WithRefinement1` interfaces (@gcanti)
|
46 | - add `WithUnknownContainers` / `WithUnknownContainers1` interfaces (@gcanti)
|
47 | - move `UnknownArray` and `UnknownRecord` to `WithUnknownContainers` (@gcanti)
|
48 | - `Schema`
|
49 | - refactoring with the new `Schemable` interface (@gcanti)
|
50 | - add `interpreter` function (@gcanti)
|
51 | - **Internal**
|
52 | - upgrade to `typescript@3.9.3` (@gcanti)
|
53 |
|
54 | # 2.2.2
|
55 |
|
56 | - **Experimental**
|
57 | - add `Eq` module (@gcanti)
|
58 | - `Codec`
|
59 | - add `TypeOf` operator (@gcanti)
|
60 | - `Decoder`
|
61 | - add `DecodeError` interface (@gcanti)
|
62 | - `Encoder`
|
63 | - add `TypeOf` operator (@gcanti)
|
64 | - `Guard`
|
65 | - add `TypeOf` operator (@gcanti)
|
66 |
|
67 | # 2.2.1
|
68 |
|
69 | - **Experimental**
|
70 | - `Decoder`
|
71 | - collect all errors while decoding, closes #449 (@gcanti)
|
72 |
|
73 | # 2.2.0
|
74 |
|
75 | - **Experimental**
|
76 | - add `Codec`, `Decoder`, `Encoder`, `Guard`, `Schema`, `Schemable`, `Tree` modules (@gcanti)
|
77 |
|
78 | # 2.1.3
|
79 |
|
80 | - **Polish**
|
81 | - remove useless `hasOwnProperty` calls, closes #423 (@gcanti)
|
82 |
|
83 | # 2.1.1
|
84 |
|
85 | - **Bug Fix**
|
86 | - fix `record` domain handling, closes #391 (@gcanti)
|
87 |
|
88 | # 2.1.0
|
89 |
|
90 | - **New Feature**
|
91 | - add `bigint` codec (@mixedCase)
|
92 |
|
93 | # 2.0.6
|
94 |
|
95 | - **Bug Fix**
|
96 | - whitelist `window` in `UnknownRecord`, fix #413 (@gcanti)
|
97 |
|
98 | # 2.0.5
|
99 |
|
100 | - **Bug Fix**
|
101 | - `partial` shouldn't allow arrays, fix #407 (@gcanti)
|
102 |
|
103 | # 2.0.4
|
104 |
|
105 | - **Bug Fix**
|
106 | - remove getters, fix #404 (@gcanti)
|
107 |
|
108 | # 2.0.3
|
109 |
|
110 | - **Bug Fix**
|
111 | - rewrite es6 imports (@gcanti)
|
112 |
|
113 | # 2.0.2
|
114 |
|
115 | - **Bug Fix**
|
116 | - fix #397 (@gcanti)
|
117 |
|
118 | # 2.0.1
|
119 |
|
120 | - **Bug Fix**
|
121 | - fix `getTags` algorithm for mutually recursive codecs, closes #354 (@gcanti)
|
122 |
|
123 | # 2.0.0
|
124 |
|
125 | - **Breaking Change**
|
126 | - upgrade to `fp-ts@2.x` (@gcanti)
|
127 | - move `fp-ts` to `peerDependencies` (@gcanti)
|
128 |
|
129 | # 1.10.4
|
130 |
|
131 | - **Polish**
|
132 | - remove unneeded internal code (@gcanti)
|
133 |
|
134 | # 1.10.3
|
135 |
|
136 | - **Bug Fix**
|
137 | - revert `1.10.0` compatibility, fix #344 (@gcanti)
|
138 |
|
139 | # 1.10.2
|
140 |
|
141 | - **Bug Fix**
|
142 | - move `fp-ts` back to dependencies (@gcanti)
|
143 |
|
144 | # 1.10.1
|
145 |
|
146 | - **Bug Fix**
|
147 | - handle `strict`, `exact` and `refinement` codecs when optimizing tagged unions, fix #339 (@gcanti)
|
148 |
|
149 | # 1.10.0
|
150 |
|
151 | - **New Feature**
|
152 | - make `io-ts` compatible with both `fp-ts@1.x`, `fp-ts@2.x` (@gcanti)
|
153 |
|
154 | # 1.9.0
|
155 |
|
156 | - **New Feature**
|
157 | - `union` is now able to detect and optimize tagged unions (@gcanti)
|
158 | - **Deprecation**
|
159 | - deprecate `taggedUnion` in favour of `union` (@gcanti)
|
160 |
|
161 | # 1.8.6
|
162 |
|
163 | output ES modules to better support tree-shaking, closes #326 (@gcanti)
|
164 |
|
165 | # 1.8.5
|
166 |
|
167 | - **Bug Fix**
|
168 | - change how types and output types are retrieved in `IntersectionC` and `TupleC`, fix #315 (@gcanti)
|
169 |
|
170 | # 1.8.4
|
171 |
|
172 | - **Polish**
|
173 | - autobind `decode` method (@gcanti)
|
174 |
|
175 | # 1.8.3
|
176 |
|
177 | - **Polish**
|
178 | - add `stripInternal` flag to `tsconfig.json` (@gcanti)
|
179 | - handle `NaN` in `PathReporter` (@gcanti)
|
180 | - throw if union encoding doesn't find a usable codec (@leemhenson)
|
181 | - **Deprecation**
|
182 | - deprecate `NeverType` (@gcanti)
|
183 | - deprecate `FunctionType` (@gcanti)
|
184 |
|
185 | # 1.8.2
|
186 |
|
187 | - **Bug Fix**
|
188 | - align the runtime behavior of `Exact.is` with the type system, fix #288 (@gcanti)
|
189 |
|
190 | # 1.8.1
|
191 |
|
192 | - **New Feature**
|
193 | - add `brand` combinator (@gcanti, @lostintime)
|
194 | - add `Int` codec (@gcanti)
|
195 | - `exact` strips additional properties while decoding / encoding (@gcanti)
|
196 | - un-deprecate `strict` combinator, is now an alias of `exact(type(...))` (@gcanti)
|
197 | - **Bug Fix**
|
198 | - fix wrong context keys for tagged unions (@gcanti)
|
199 | - **Deprecation**
|
200 | - deprecate `refinement` combinator in favour of `brand` (@gcanti)
|
201 | - deprecate `Integer` codec in favour of `Int` (@gcanti)
|
202 | - deprecate `StrictType` class (@gcanti)
|
203 | - deprecate `StrictC` interface (@gcanti)
|
204 | - **Polish**
|
205 | - modify the implementation of `intersection` in order to support combinators that strip additional properties (@gcanti)
|
206 | - do not validate the codomain of a key of a record if its domain in invalid (@gcanti)
|
207 | - normalize missing `message` field in `ValidationError` (@gcanti)
|
208 | - fix name of recursive codec definitions (@gcanti)
|
209 | - remove unexpected validation path from partial type, closes #195 (@gcanti)
|
210 | - do not leak taggedUnion implementation when tag validation fails (@gcanti)
|
211 | - add `actual` value to all context entries (@gcanti)
|
212 | - `exact` now bails out when the value is not an `UnknownRecord` (@gcanti)
|
213 | - `tuple` should not leak the implementation (`never` usage) (@gcanti)
|
214 | - `exact` should not leak the implementation (`never` usage) (@gcanti)
|
215 | - use `Number.isInteger` in `Integer` implementation (@gcanti)
|
216 | - use the Flow convention to name `exact` codecs (@gcanti)
|
217 |
|
218 | # 1.7.1
|
219 |
|
220 | - **Deprecation**
|
221 | - deprecate `any` (@gcanti)
|
222 | - deprecate `object` (@gcanti)
|
223 | - deprecate `Dictionary` in favour of `UnknownRecord` (@gcanti)
|
224 | - deprecate `Array` in favour of `UnknownArray` (@gcanti)
|
225 | - deprecate `dictionary` in favour of `record` (@gcanti)
|
226 |
|
227 | # 1.7.0
|
228 |
|
229 | - **New Feature**
|
230 | - better support for custom messages, closes #148 (@gcanti)
|
231 | - add optional message field to `ValidationError`
|
232 | - add `message` argument to `failure`
|
233 | - `PathReporter` should account for the new field
|
234 | - add `actual` optional field to `ContextEntry`, closes #194 (@gcanti)
|
235 | - **Deprecation**
|
236 | - deprecate `getValidationError` (@gcanti)
|
237 | - deprecate `getDefaultContext` (@gcanti)
|
238 |
|
239 | # 1.6.4
|
240 |
|
241 | - **Bug Fix**
|
242 | - `getIndexRecord`: getIndexRecord: handle conflicting tags in different positions, ref #263 (@gcanti)
|
243 | - **Experimental**
|
244 | - added a warning to the console if a tagged union cannot be created (@gcanti)
|
245 | - revert `union` optimization, needs more work to make it happen (@gcanti)
|
246 |
|
247 | # 1.6.3
|
248 |
|
249 | - **Bug Fix**
|
250 | - prevent maximum call stack size exceeded when indexing recursive codecs, closes #259 (@gcanti)
|
251 |
|
252 | # 1.6.2
|
253 |
|
254 | - **Polish**
|
255 | - make `isIndexableCodec` more strict (@gcanti)
|
256 |
|
257 | # 1.6.1
|
258 |
|
259 | - **Bug Fix**
|
260 | - `taggedUnion` should handle sub unions / tagged unions correctly, closes #257 (@gcanti)
|
261 | - **Experimental**
|
262 | - optimize `union` with the same algorithm used in `taggedUnion` (@gcanti)
|
263 |
|
264 | # 1.6.0
|
265 |
|
266 | **Important**. This version requires `typescript@3.2.2+`
|
267 |
|
268 | - **New Feature**
|
269 | - leverage `typescript@3.2.2` (@gcanti)
|
270 | - `TypeC`
|
271 | - `PartialC`
|
272 | - `RecordC`
|
273 | - `UnionC`
|
274 | - `ReadonlyC`
|
275 | - `StrictC`
|
276 | - `TaggedUnionC`
|
277 |
|
278 | # 1.5.3
|
279 |
|
280 | - **Bug Fix**
|
281 | - missing context info while decoding an intersection, fix #246 (@gcanti)
|
282 | - **Experimental**
|
283 | - add intermediary interfaces, closes #165 (@gcanti)
|
284 | - `NullC`
|
285 | - `UndefinedC`
|
286 | - `VoidC`
|
287 | - `AnyC`
|
288 | - `UnknownC`
|
289 | - `NeverC`
|
290 | - `StringC`
|
291 | - `NumberC`
|
292 | - `BooleanC`
|
293 | - `UnknownArrayC`
|
294 | - `UnknownRecordC`
|
295 | - `ObjectC`
|
296 | - `FunctionC`
|
297 | - `RefinementC`
|
298 | - `LiteralC`
|
299 | - `KeyofC`
|
300 | - `ArrayC`
|
301 | - `TypeC`
|
302 | - `PartialC`
|
303 | - `RecordC`
|
304 | - `UnionC`
|
305 | - `IntersectionC`
|
306 | - `TupleC`
|
307 | - `ReadonlyC`
|
308 | - `ReadonlyArrayC`
|
309 | - `StrictC`
|
310 | - `TaggedUnionC`
|
311 | - `ExactC`
|
312 | - **Polishs**
|
313 | - use rest elements in tuple types (`typescript@3.0.1` feature) (@gcanti)
|
314 | - `union` should handle zero types (@gcanti)
|
315 | - `intersection` should handle zero / one types (@gcanti)
|
316 | - **Deprecation**
|
317 | - deprecate `clean` (@gcanti)
|
318 | - deprecate `alias` (@gcanti)
|
319 | - deprecate `PropsOf` type (@gcanti)
|
320 | - deprecate `Exact` type (@gcanti)
|
321 |
|
322 | # 1.5.2
|
323 |
|
324 | - **Deprecation**
|
325 | - deprecate `Compact` type (@gcanti)
|
326 |
|
327 | # 1.5.1
|
328 |
|
329 | - **Polish**
|
330 | - remove useless module augmentation of `Array` (@gcanti)
|
331 |
|
332 | # 1.5.0
|
333 |
|
334 | - **New Feature**
|
335 | - add `UnknownType`, closes #238 (@gcanti)
|
336 | - **Deprecation**
|
337 | - `ThrowReporter` is now deprecated (@gcanti)
|
338 |
|
339 | # 1.4.2
|
340 |
|
341 | use `Compact` in `intersection` signatures as a workaround for #234 (@sledorze)
|
342 |
|
343 | # 1.4.1
|
344 |
|
345 | - **Polish**
|
346 | - `Type.prototype.pipe` now allows more types as input, #231 #232 (@sledorze)
|
347 |
|
348 | # 1.4.0
|
349 |
|
350 | - **New Feature**
|
351 | - use `unknown` as `mixed` (@gcanti)
|
352 |
|
353 | # 1.3.4
|
354 |
|
355 | - **Bug Fix**
|
356 | - should emit expected keys while decoding, fix #214 (@gcanti)
|
357 |
|
358 | # 1.3.3
|
359 |
|
360 | - **Bug Fix**
|
361 | - align `TaggedExact` definition with siblings, fix #223 (@gcanti)
|
362 |
|
363 | # 1.3.2
|
364 |
|
365 | - **Bug Fix**
|
366 | - dictionary type should not allow arrays, fix #218 (@gcanti)
|
367 |
|
368 | # 1.3.1
|
369 |
|
370 | - **Polish**
|
371 | - use interface instead of type alias (@gcanti)
|
372 | - `Context`
|
373 | - `Errors`
|
374 | - `Any`
|
375 | - `Mixed`
|
376 |
|
377 | # 1.3.0
|
378 |
|
379 | - **New Feature**
|
380 | - add `TaggedUnionType` (@gcanti)
|
381 |
|
382 | # 1.2.1
|
383 |
|
384 | - **Polish**
|
385 | - allow recursive types in tagged unions (@gcanti)
|
386 |
|
387 | # 1.2.0
|
388 |
|
389 | - **New Feature**
|
390 | - add `void` runtime type (@gcanti)
|
391 |
|
392 | # 1.1.5
|
393 |
|
394 | - **Bug Fix**
|
395 | - partial combinator should preserve additional properties while encoding, fixes #179 (@gcanti)
|
396 | - **Polish**
|
397 | - use `useIdentity` when possible (@gcanti)
|
398 |
|
399 | # 1.1.4
|
400 |
|
401 | - **Internal**
|
402 | - fix broken build with `typescript@2.9.1`, closes #174 (@gcanti)
|
403 |
|
404 | # 1.1.3
|
405 |
|
406 | - **Internal**
|
407 | - upgrade to `typings-checker@2.0.0` (@gcanti)
|
408 |
|
409 | # 1.1.2
|
410 |
|
411 | - **Bug Fix**
|
412 | - fix `alias` implementation (@gcanti)
|
413 | - handle exact types in `isTagged` (@gcanti)
|
414 |
|
415 | # 1.1.1
|
416 |
|
417 | - **Experimental**
|
418 | - add `clean` / `alias` functions, closes #149 (@gcanti)
|
419 | - add `exact` combinator (@gcanti)
|
420 | - the `strict` combinator is deprecated
|
421 | - remove `optional` combinator (@gcanti)
|
422 | - it doesn't play well with advanced combinators, see [here](https://github.com/gcanti/io-ts/issues/140) for a discussion
|
423 |
|
424 | # 1.0.6
|
425 |
|
426 | - **Bug Fix**
|
427 | - `taggedUnion` fails to decode when tag values are not string literals, fix #161 (@gcanti)
|
428 |
|
429 | # 1.0.5
|
430 |
|
431 | - **Bug Fix**
|
432 | - workaround for upstream TypeScript bug 14041 (wrong generated declarations) (@gcanti)
|
433 | - **Internal**
|
434 | - optimize InterfaceType.encode (@gcanti)
|
435 | - use definite assignment assertion for phantom fields (@gcanti)
|
436 |
|
437 | # 1.0.4
|
438 |
|
439 | - **Bug Fix**
|
440 | - make `Context` readonly (@gcanti)
|
441 | - **Internal**
|
442 | - optimizations, #137 (@gcanti, @sledorze)
|
443 |
|
444 | # 1.0.3
|
445 |
|
446 | - **Internal**
|
447 | - optimizations, #134 (@gcanti, @sledorze)
|
448 |
|
449 | # 1.0.2
|
450 |
|
451 | - **Bug Fix**
|
452 | - fix `OutputOfPartialProps` name (@gcanti)
|
453 |
|
454 | # 1.0.1
|
455 |
|
456 | - **Bug Fix**
|
457 | - fix `AnyType` by extending `Type<any>` (@gcanti)
|
458 |
|
459 | # 1.0.0
|
460 |
|
461 | - **Breaking Change**
|
462 | - upgrade to `fp-ts@1.0.0`
|
463 | - see https://github.com/gcanti/io-ts/pull/112 (@gcanti)
|
464 |
|
465 | # 0.9.8
|
466 |
|
467 | - **New Feature**
|
468 | - add decode and deprecate top level validate (@gcanti)
|
469 | - **Internal**
|
470 | - when checking validations use methods instead of top level functions (@gcanti)
|
471 |
|
472 | # 0.9.7
|
473 |
|
474 | - **New Feature**
|
475 | - add `taggedUnion` combinator (@gcanti, @sledorze)
|
476 |
|
477 | # 0.9.6
|
478 |
|
479 | - **New Feature**
|
480 | - `recursive` combinator
|
481 | - add support for mutually recursive types, closes #114 (@gcanti)
|
482 | - make it safer: `RT` now must extend `Type<mixed, A>` (@gcanti)
|
483 |
|
484 | # 0.9.5
|
485 |
|
486 | - **New Feature**
|
487 | - add `mixed` type (@gcanti)
|
488 | - replace `any` with `mixed` in all input type parameters (@gcanti)
|
489 | ```diff
|
490 | -export class StringType extends Type<any, string> {
|
491 | +export class StringType extends Type<mixed, string> {
|
492 | }
|
493 | ```
|
494 |
|
495 | # 0.9.4
|
496 |
|
497 | - **Bug Fix**
|
498 | - strict: should succeed validating an undefined field, closes #106 (@gcanti)
|
499 |
|
500 | # 0.9.3
|
501 |
|
502 | - **Bug Fix**
|
503 | - revert 37c74a5e2038de063a950f9ba8d18b1f132ef450, closes #8 (@gcanti)
|
504 |
|
505 | # 0.9.2
|
506 |
|
507 | - **New Feature**
|
508 | - add `Decoder` / `Encoder` interfaces (@sledorze, @gcanti)
|
509 | - **Internal**
|
510 | - perf optimizations (@sledorze, @gcanti)
|
511 |
|
512 | # 0.9.1
|
513 |
|
514 | - **Bug Fix**
|
515 | - make all classes "dumb", fix #95 (@gcanti)
|
516 |
|
517 | # 0.9.0
|
518 |
|
519 | - **Breaking Change**
|
520 | - remove `t.map` and `t.mapWithName` (in general doesn't look serializable, needs more investigation)
|
521 | - remove `t.prism` (in general doesn't look serializable, needs more investigation)
|
522 | - change `Type` from interface to class and add `S` type parameter
|
523 | - remove `t._A`
|
524 | - add `Type#serialize`
|
525 | - add `Type#is` (in order to serialize unions and while we're at it, looks useful anyway)
|
526 | - remove `t.is` (now that there's `Type#is` is misleading)
|
527 | - **Experimental**
|
528 | - add Flowtype support (@gcanti)
|
529 |
|
530 | # 0.8.2
|
531 |
|
532 | - **New Feature**
|
533 | - add `object` type, closes #86 (@gcanti)
|
534 |
|
535 | # 0.8.1
|
536 |
|
537 | - **New Feature**
|
538 | - add `strict` combinator, closes #84 (@phiresky, @gcanti)
|
539 |
|
540 | # 0.8.0
|
541 |
|
542 | - **Breaking Change**
|
543 | - upgrade `fp-ts` dependency (@gcanti)
|
544 |
|
545 | # 0.7.2
|
546 |
|
547 | - **Bug Fix**
|
548 | - tag recursive types, fix #80 (@gcanti)
|
549 |
|
550 | # 0.7.1
|
551 |
|
552 | - **Bug Fix**
|
553 | - incorrect compile time type for dictionary, fix #75 (@gcanti)
|
554 |
|
555 | # 0.7.0
|
556 |
|
557 | - **Breaking Change**
|
558 | - upgrade to latest fp-ts (0.5.1) (@gcanti)
|
559 |
|
560 | # 0.6.2
|
561 |
|
562 | - **New Feature**
|
563 | - add aliases for `null` and `interface`, closes #63 (@gcanti)
|
564 |
|
565 | # 0.6.1
|
566 |
|
567 | - **Internal**
|
568 | - handle latest fp-ts (0.4.3) (@gcanti)
|
569 |
|
570 | # 0.6.0
|
571 |
|
572 | - **Breaking Change**
|
573 | - upgrade to latest fp-ts (0.4.0) (@gcanti)
|
574 | - **Internal**
|
575 | - allow for infinite unions (@gcanti)
|
576 |
|
577 | # 0.5.1
|
578 |
|
579 | - **Bug Fix**
|
580 | - export and rename `interfaceType` to `_interface`, fix #57 (@gcanti)
|
581 |
|
582 | # 0.5.0
|
583 |
|
584 | - **Breaking Change**
|
585 | - `Type` is now an interface
|
586 | - types no more own a `is` method, use `t.is` instead
|
587 | - unions no more own a `fold` method
|
588 | - `Reporter`, `PathReporter`, `ThrowReporter` are now top level modules
|
589 |
|
590 | # 0.4.0
|
591 |
|
592 | - **Breaking Change**
|
593 | - upgrade to latest `fp-ts` (`io-ts` APIs are not changed though) (@gcanti)
|
594 | - drop `lib-jsnext` folder
|
595 |
|
596 | # 0.3.2
|
597 |
|
598 | - **Bug Fix**
|
599 | - remove excess overloadings, fix #43 (@gcanti)
|
600 |
|
601 | # 0.3.1
|
602 |
|
603 | - **New Feature**
|
604 | - add mapWithName and Functor instance, fix #37 (@gcanti)
|
605 | - add prism combinator, fix #41 (@gcanti)
|
606 |
|
607 | # 0.3.0
|
608 |
|
609 | This is a breaking change _only_ if you are using fp-ts APIs
|
610 |
|
611 | - **Breaking Change**
|
612 | - upgrade to latest fp-ts v0.2 (@gcanti)
|
613 |
|
614 | # 0.2.3
|
615 |
|
616 | - **Internal**
|
617 | - upgrade to fp-ts v0.1 (@gcanti)
|
618 |
|
619 | # 0.2.2
|
620 |
|
621 | - **New Feature**
|
622 | - add `partial` combinator (makes optional props possible)
|
623 | - add `readonly` combinator (values are not frozen in production)
|
624 | - add `readonlyArray` combinator (values are not frozen in production)
|
625 | - add `never` type
|
626 | - **Breaking Changes**
|
627 | - remove `maybe` combinator, can be defined in userland as
|
628 | ```ts
|
629 | export function maybe<RT extends t.Any>(
|
630 | type: RT,
|
631 | name?: string
|
632 | ): t.UnionType<[RT, typeof t.null], t.TypeOf<RT> | null> {
|
633 | return t.union([type, t.null], name)
|
634 | }
|
635 | ```
|
636 | - **Polish**
|
637 | - export `pathReporterFailure` function from default reporters
|
638 | - **Bug Fix**
|
639 | - revert pruning excess properties (see https://github.com/gcanti/io-ts/pull/27 for context)
|
640 | - revert `intersection` combinator accepting only `InterfaceType`s
|
641 | - **Experimental**
|
642 | - Pattern matching / catamorphism for unions
|
643 |
|
644 | # 0.1.0
|
645 |
|
646 | - **New Feature**
|
647 |
|
648 | - add support for jsnext
|
649 | - add `Integer` type
|
650 |
|
651 | - **Breaking Changes**
|
652 | - `t.Object` type. Renamed to `t.Dictionary`, now accepts arrays so is fully equivalent to `{ [key: string]: any }`.
|
653 | - `t.instanceOf` combinator. Removed.
|
654 | - `t.object` combinator. Renamed to `t.interface`. `ObjectType` to `InterfaceType`. Excess properties are now pruned.
|
655 | - `mapping` combinator. Renamed to `dictionary`. `MappingType` to `DictionaryType`.
|
656 | - `intersection` combinator. Due to the new excess property pruning in `t.interface` now only accept `InterfaceType`s.
|
657 | - API `isSuccess` removed, use `either.isRight` instead
|
658 | - API `isFailure` removed, use `either.isLeft` instead
|
659 | - API `fromValidation` removed
|
660 |
|
661 | # 0.0.2
|
662 |
|
663 | - **Bug Fix**
|
664 | - reverse overloading definitions for unions, intersections and tuples, fix inference bug
|
665 |
|
666 | # 0.0.1
|
667 |
|
668 | Initial release
|