Skip to content

Releases: unional/type-plus

[email protected]

07 Feb 06:55
Compare
Choose a tag to compare
[email protected] Pre-release
Pre-release

Minor Changes

  • 335b870: Rename $ExactOptions to $Exact.Options,
    $ExactDefault to $Exact.Default,
    $IsExact to $Exact.Parse
  • 4b2b89c: Replace Equal with the new $Equal type.
  • d418300: Rename $IsDistributive to $Distributive.Parse.
  • 1debfc2: $Equality to $Equal.
  • 407b3d3: Deprecate NoInfer.
  • 3d70869: Remove $Override. It is not needed.
  • abdc5fe: Update bit types
  • 53f6c0b: Consolidate $Selection types.
  • 1c7bab7: Deprecate Failed and FailedT.
  • 2ed6063: Update $Type to work with primitive types and improve object type usage.
  • 19663d7: Rename $SpecialType to $Special.
  • f09ef4d: Add $Void support.
  • d5e732a: Update Equal signature and implementation.
    Deprecate IsEqual and IsNotEqual in favor of Equal.
  • 5263e8f: Rename $DistributiveOptions to $Distributive.Options and $DistributiveDefault to $Distributive.Default.
  • 51a7bea: Rename $Select to $Equal.
    Remove $SelectStrict, use $Equal<T, U, { exact: true }> instead.
  • b150471: Updato logical types.
  • ed723c7: Add $Void support to IsAny and IsNotAny.
  • c56d4a0: Change $ResolveBranch type parameters order.
    T is moved to the last position as D (as it is the default value), and made optional.
  • b364e73: Export $Exact.

Patch Changes

  • e110219: Fix $ResolveOptions type to handle undefined value.

  • 20ded29: Use fn.apply instead of spread.
    It has better performance and function that are already bound continue to work as expected.

    const bindFn = fn.bind(This);
    
    bindFn.apply(null, args); // `this` is not affected

[email protected]

27 Sep 18:35
Compare
Choose a tag to compare
[email protected] Pre-release
Pre-release

Minor Changes

  • cb37ca4: Add AdjustExactOptionalProps.

[email protected]

26 Sep 11:38
Compare
Choose a tag to compare
[email protected] Pre-release
Pre-release

Minor Changes

  • 17bf492: Remove $Exact namespace.
    $Exact.$Options is now $ExactOptions.
    $Exact.$Default is now $ExactDefault.
    $Exact.$IsExact is now $IsExact.

Patch Changes

  • ac73d79: Removing incorrect usage of the typesVersions field in package.json.
  • 1e5108d: Add SubUnion type.
  • 37e47dc: Remove $Exact branch type. It is not needed anymore.

[email protected]

02 Aug 09:09
Compare
Choose a tag to compare
[email protected] Pre-release
Pre-release

Minor Changes

  • 2d4d9b4: Reintroduce CJS support.

[email protected]

27 Jul 00:31
Compare
Choose a tag to compare
[email protected] Pre-release
Pre-release

Patch Changes

  • bbe256c: Remove exports.default in package.json.

    That provide the wrong file to systems expecting CJS.
    May need to add a different one for browser-spec.

[email protected]

25 Mar 02:46
Compare
Choose a tag to compare
[email protected] Pre-release
Pre-release

Minor Changes

  • f982121: Update to require typescript 5.4.

Patch Changes

  • 4ae069b: Fix IsPositive<number & { a: 1 }> should return boolean
  • 7227250: Simplify Omit type as the simpler code is working with typescript 5.4
  • 8901e75: Work around excessive stack depth error in TS 5.4 for type Zeros.
  • b480c6c: Update some docs under numerics
  • 3d56d1a: Fix IsInteger<number & { a: 1 }> should returns boolean
  • cc94afd: Fix IsNegative<number & { a: 1 }> should return boolean

[email protected]

17 Mar 03:41
Compare
Choose a tag to compare

Fixed excessive stack depth error around Zeros type #427 by @ehoogeveen-medweb

Simplify Omit type as the simpler code is working with typescript 5.4

[email protected]

13 Sep 05:56
Compare
Choose a tag to compare
[email protected] Pre-release
Pre-release

Major Changes

  • 2a0d791: Rename case* to $* to make them easier to use.
  • 0616400: Update and release as ESM package only.

Minor Changes

  • afac18a: Add IsStrictObject<T> type.

  • b98ed6d: Accept readonly for array.
    Add ArrayPlus.IsReadonly.

    Fix ArrayPlus.Reverse to support readonly.

  • 69c5409: Add Merge<A, B> and ObjectPlus.Merge<A, B>

  • de54957: Add customize support for ArrayPlus.Filter

  • 7116392: Add Box<T> to box primitive types to their boxed types.

Patch Changes

  • 3ed4dce: Optimize SplitAt by moving never check of DeleteCount to the top.

  • 5535a4a: fix IsArray<never[]>

  • d852d76: Add docs for ArrayPlus.IsReadonly.

    The following are internal changes thus not considered a breaking change:

    • Replace MergeOptions/MergeCases with TypePlusOptions.Merge.
    • Rename TypePlusOptions.Predicate to TypePlusOptions.Selection.

[email protected]

08 Jul 20:52
Compare
Choose a tag to compare

Minor Changes

  • 036094b: Support Delete and Insert for SplitAt.

Patch Changes

[email protected]

05 Jul 07:57
Compare
Choose a tag to compare

Minor Changes

  • 4f1e6e8: Add UnionType and IsUnion

  • 1bee392: Improve FindFirst and ArrayPlus.Find to support union_miss and never cases,
    and some bug fixes.

  • b3d0af0: Export the improved Required type.

  • bc535d4: Support customization for Head and Tail

  • d2f97ca: Add options support for:

    • TupleType, IsTuple, NotTupleType, IsNotTuple
    • DropFirst, DropLast,
    • FindFirst, ArrayPlus.FindFirst, TuplePlus.FindFirst

    Add MergeOptions.
    Add NotUnknownOr (all use cases are handled by MergeOptions at the moment)

  • 94bb1c0: Improve FindFirst,
    add ArrayPlus.Find and TuplePlus.Find

  • 4e7e310: Clean up CommonPropKeys.

    Add ArrayPlus.CommonPropKeys and TuplePlus.CommonPropKeys.
    Add support of caseNever.

  • 7a647ca: Support override never case for TupleType, IsTuple, IsNotTuple, and NotTupleType

Patch Changes

  • 91211c9: Rename caseNoMatch to caseNotMatch.
    Rename caseUnionMiss to caseUnionNotMatch.

    Change caseUnionNotMatch default from undefined to never,
    making it defaults to the type behavior instead of JavaScript behavior.

  • 8a60488: Move TestType under testType so that it is exported