Functional programming (`fpdart`)
·
7 commits
to main
since this release
This PR refactors the code to add Functional programming with the fpdart
package.
Functional programming makes error handling in the app more solid and safe. These are the main changes:
- Updated return type in
repository
fromFuture
toTaskEither
- Added error types for each request
- Refactored repository implementations to return
TaskEither
(usingfpdart
's methods liketryCatch
,flatMap
,map
) - Execute requests and display error message based on the type of error returned (
Either
type)
What's Changed
- Functional programming (
fpdart
) [6] by @SandroMaglione in #7