Releases: unional/type-plus
[email protected]
Patch Changes
- 90eb2a4: Update package.json try fixing readme references
[email protected]
Minor Changes
- e8547eb: Add
IsOptionalKey<T, K>
. - bd6c695: Add
OptionalProps<T>
.
ImproveOptionalKeys<T>
andIsOptionalKey<T, K>
- d3faa0b: Add
OptionalKeys<T>
Patch Changes
-
d214ce6: Improve
testType.inspect<T>(fn)
to provide more information aboutT
.Not consider as breaking change as the function is not expected to be use in any code.
[email protected]
[email protected]
Minor Changes
- a52cce0: Add
testType.inspect<T>(fn)
for easy type inspection.
[email protected]
Patch Changes
- 26537d8: Improve
RecursivePartial
to work with function type.
Also add| undefined
to make it compliant withexactOptionalPropertyTypes
.
[email protected]
v7.0.1
v7.0.0
Major Changes
-
91c954f: Remove
Digit
andDigitArray
.They are internal types to begin with.
They were exported probably to fix the "type cannot be named" error. -
469c8bd: Fix array
PadStart
/PadLeft
that triggers an infinite loop.Change default
PadWith
fromany
tounknown
(breaking).
Minor Changes
-
Update
Add
,Subtract
, and addedMultiply
which now works withnumber
,bigint
, positive, negative, and floating point. -
e11d43c: Expose
FindLast
also asArrayPlus.FindList
.Improved its handling of array.
-
25e5fcb: add
NumericPlus
-
ee14247: Add
ArrayPlus.SplitAt
-
a49abe2: Mark the following code as deprecated:
isType.t()
isType.f()
isType.never()
-
4352d51: Add
StringToNumber
,StringToBigint
, andStringToNumeric
-
e93e366: Add alternative
Partial<T>
type that works withexactOptionalPropertyTypes
. -
10af363: Add
ArrayPlus.Reverse<A>
-
82ffd7d: Add
NumericToString
-
72aca9d: Add
MathPlus.ToNegative
-
09495be: Add
ArrayPlus.Entries<A>
. -
3e0e199: Add remaining types to
testType.*
.testType
is changed to a proxy to simplify implementation. -
73bbcf0: Add
PadStart
, deprecasePadLeft
-
65e84c4: Expose
FindFirst
also asArrayPlus.Find
.Improved its handling of array.
-
d2997de: Deprecate
Equal
andNotEqual
. They are renamed toIsEqual
andIsNotEqual
.Equal
andNotEqual
will be changed tofilter
variant (a.k.a.parse
variant) in the future. -
180a455: Add
TuplePlus.PadStart
. -
7bf5d39: Add
StrictCanAssign<A,B>
andtestType.strictCanAssign()
-
010a788: Deprecate
assertType(subject constructor)
.
AddT/F
toExtendable
andNotExtendable
. -
74cc654: Alias
Some
underArrayPlus.Some
. -
4054c64:
GreaterThan
andMax
now support floating point and negative numbers, andbigint
Patch Changes
-
8461752:
At
should returnV | undefined
for tuple whenN
isnumber
(orany
which includesnumber
). -
aaffd23: fix
Some<Array<number | string>, number>
to returnboolean
.
This is because besidesArray<number | string>
can be[1, 'a']
,
it can also be:const v: number | string = 123 const a: Array<number | string> = [v]
So
Some<Array<number | string>, number>
should distribute and returnboolean
. -
4878eb0:
At
should returnV | undefined
for array. -
afc1840: Add
Upper
andLower
forIndexAt
.This allow fine-grained control over the
IndexAt
behavior,
when the value is out of bounds.This is used in cases where out-of-bounds values are coarsen to the upper and lower bound of the subject array.
-
d31ea31: Improve
Abs
to work withbigint