Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump fpdart from 0.2.0 to 0.4.1 #5

Closed
wants to merge 1 commit into from

Conversation

dependabot[bot]
Copy link

@dependabot dependabot bot commented on behalf of github Feb 27, 2023

Bumps fpdart from 0.2.0 to 0.4.1.

Release notes

Sourced from fpdart's releases.

v0.4.1

  • New methods for Option type (thanks to tim-smart 🎉)
    • flatMapNullable
    • flatMapThrowable
final option = Option.of(10);
option.flatMapNullable((a) => a + 1); /// 👈 Some(11)
option.flatMapThrowable((a) => a + 1); /// 👈 Some(11)
option.flatMapNullable<int>((a) => null); /// 👈 None()
option.flatMapThrowable<int>((a) => throw "fail"); /// 👈 None()

  • Improved support fromJson for Option type (thanks [again] to tim-smart 🎉)
    • Allow for decoding of non-primitive types (with custom fromJson constructors)
/// `fromJson` on `DateTime` with `Option` type
final now = DateTime.now();
Option<DateTime>.fromJson(now.toIso8601String(), (a) => DateTime.parse(a as String)); /// 👈 `Some(now)`
Option<DateTime>.fromJson("fail", (a) => DateTime.parse(a as String)); /// 👈 None()

  • New extension methods for Map (thanks [once again] to tim-smart 🎉)
    • extract
    • extractMap
final map = <String, dynamic>{'a': 1, 'b': 2, 'c': 3, 'd': 4};
map.extract<int>('b'); /// 👈 `Some(2)`
map.extract<String>('b'); /// 👈 `None()`, not of type `String` ⚠️
final map = <String, dynamic>{'a': 1};
map.extractMap('a'); /// 👈 None(), not a Map
final map = <String, dynamic>{'a': {'b': 2} };
map.extractMap('a'); /// 👈 Some({'b': 2})

  • Option.of and Option.none factories const (thanks to f-person 🎉)

Note: People who have the prefer_const_constructors lint enabled will notice a warning to use const 🤝

v0.4.0

  • Added extension methods to work with nullable types (T?)
    • From T? to fpdart's types
      • toOption

... (truncated)

Changelog

Sourced from fpdart's changelog.

v0.4.1 - 25 February 2023

  • New methods for Option type (thanks to tim-smart 🎉)
    • flatMapNullable
    • flatMapThrowable
final option = Option.of(10);
option.flatMapNullable((a) => a + 1); /// 👈 Some(11)
option.flatMapThrowable((a) => a + 1); /// 👈 Some(11)
option.flatMapNullable<int>((a) => null); /// 👈 None()
option.flatMapThrowable<int>((a) => throw "fail"); /// 👈 None()

  • Improved support fromJson for Option type (thanks [again] to tim-smart 🎉)
    • Allow for decoding of non-primitive types (with custom fromJson constructors)
/// `fromJson` on `DateTime` with `Option` type
final now = DateTime.now();
Option<DateTime>.fromJson(now.toIso8601String(), (a) => DateTime.parse(a as String)); /// 👈 `Some(now)`
Option<DateTime>.fromJson("fail", (a) => DateTime.parse(a as String)); /// 👈 None()

  • New extension methods for Map (thanks [once again] to tim-smart 🎉)
    • extract
    • extractMap
final map = <String, dynamic>{'a': 1, 'b': 2, 'c': 3, 'd': 4};
map.extract<int>('b'); /// 👈 `Some(2)`
map.extract<String>('b'); /// 👈 `None()`, not of type `String` ⚠️
final map = <String, dynamic>{'a': 1};
map.extractMap('a'); /// 👈 None(), not a Map
final map = <String, dynamic>{'a': {'b': 2} };
map.extractMap('a'); /// 👈 Some({'b': 2})

  • Option.of and Option.none factories const (thanks to f-person 🎉)

Note: People who have the prefer_const_constructors lint enabled will notice a warning to use const 🤝

v0.4.0 - 16 December 2022

  • Added extension methods to work with nullable types (T?)
    • From T? to fpdart's types
      • toOption

... (truncated)

Commits
  • e892c8d V0.4.1 (#91)
  • dd62057 updated README and pubspec
  • 4a12d37 v0.4.1 README and CHANGELOG
  • 899b76a feat: Option.flatMapThrowable (#89)
  • 3bafb88 feat: Option.flatMapThrowable
  • 574e62c refactor: improve fromJson support (#87)
  • 768414a chore: add Option.fromJson tests
  • 4af55ee refactor: improve fromJson support
  • c748961 Make Option.of and Option.none factories const (#85)
  • 3b1740b fix: Add type annotation to Option in flatMap and ap
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [fpdart](https://github.com/SandroMaglione/fpdart) from 0.2.0 to 0.4.1.
- [Release notes](https://github.com/SandroMaglione/fpdart/releases)
- [Changelog](https://github.com/SandroMaglione/fpdart/blob/main/CHANGELOG.md)
- [Commits](SandroMaglione/fpdart@v0.2.0...v0.4.1)

---
updated-dependencies:
- dependency-name: fpdart
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot added the dependencies Pull requests that update a dependency file label Feb 27, 2023
@dependabot @github
Copy link
Author

dependabot bot commented on behalf of github Mar 6, 2023

Superseded by #6.

@dependabot dependabot bot closed this Mar 6, 2023
@dependabot dependabot bot deleted the dependabot/pub/fpdart-0.4.1 branch March 6, 2023 08:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants