-
Notifications
You must be signed in to change notification settings - Fork 102
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
Add Maybe
Documentation
#185
Conversation
|
||
Maybe.of(add) | ||
.ap(Just(29)) | ||
.ap(Nothing()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
//=> Nothing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Docs are pretty darn easy to read! I couldn't go through all of it, but I did notice a few grammar things (if you care) in the explanations.
src/Maybe/README.md
Outdated
conditions. | ||
|
||
A `Maybe` represents disjunction by using (2) constructors, `Nothing` or `Just`. | ||
A `Just` instance represents the truth case while, `Nothing` is considered |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
methinks you don't need a comma here
src/Maybe/README.md
Outdated
|
||
Used to construct a `Just` instance that represents the "true" portion of a | ||
disjunction or a valid value. `Just` will wrap any given value in a `Just`, | ||
which signals the validity of the wrapped value. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Another comma thing... how do either of these work for ya:
`Just` will wrap any given value in a `Just`, and this signals the validity of the wrapped value.
or
`Just` will wrap any given value in a `Just`, signalling the validity of the wrapped value.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I ❤️ the latter.
src/Maybe/README.md
Outdated
``` | ||
|
||
Used to wrap any value into a `Maybe` as a `Just`, `of` is used mostly by | ||
helper functions that work "generically" with `Applicative` or `Monad` types |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"types" should probs be "type" as "instances" covers the plurality?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually think we can 🔪 the word type
altogether.
This is good...Maybe?
This PR adds the README documentation for the
Maybe
type and all of it's support functions. Also updated some issues with some of the siggys.Once this is merged, there will follow another PR to move this into the documents.
This goes against this issue