Skip to content

Releases: sbernheim4/excoptional

1.3.6

22 Jan 22:21
Compare
Choose a tag to compare

Fixes a bug where Option.of(0) would return a None() rather than a Some(0)

Skipping version 1.3.5 because I accidentally published it without first building from src. Version 1.3.5 has been removed from NPM.

1.3.4

09 Nov 18:05
Compare
Choose a tag to compare

Previously invoking None() had a return type of Option<never>. This is
not useful when modeling values that may eventually become a Some() as
the generic for that Option would not be constrained when the value is
updated causing a loss of type support.

This change carries through the generic in a None and better preserves
the type information throughout a system.

1.3.3

29 Aug 15:13
Compare
Choose a tag to compare
  • Improve type inference support. Both Some and None functions specify they return an Option. Functions that return the result of Some() or None() show they return an Option instead of the Some type as before.

1.3.2

27 Aug 16:04
Compare
Choose a tag to compare
  • Bump TypeScript package to 4.4

1.3.1

24 Aug 02:37
Compare
Choose a tag to compare
  • Improve documentation

1.3.0

24 Aug 02:37
Compare
Choose a tag to compare
  • Add new method ap which formally makes the Option an Applicative.
  • Add new static method liftN to support lifting function with arbitrary number of non option arguments to be a function of option arguments.

1.2.1

22 Aug 18:28
Compare
Choose a tag to compare
  • Improve type inference support. Explicitly specifying the return type of a function that returns an option is no longer necessary for accurate type support. Functions that return an option will be correctly inferred.

1.2.0

22 Aug 18:01
Compare
Choose a tag to compare
  • Add new static method lift.
    Option.lift is an alias for Option.map. Another name (perhaps more descriptive) for the same thing.

1.1.2

21 Aug 19:26
Compare
Choose a tag to compare
  • Fix type issue where the functional argument customToString to the log and logAndContinue methods has it's argument opt defined as optional.
  • Update README and TSDoc examples to reflect correct values in commented sections

1.1.1

21 Aug 19:16
Compare
Choose a tag to compare
  • Improves logging method capabilities.
  • Adds logAndContinue method
  • Improves log method to allow for a custom toString method to be passed as an argument.
  • Updates example sample code in the TSDocs and README