-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0a2cc20
commit 3e02b30
Showing
1 changed file
with
32 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
// Copyright © 2023 Tomoki Miyauchi. All rights reserved. MIT license. | ||
// This module is browser compatible. | ||
|
||
/** Optional values. | ||
* Type `Option` represents an optional value: every `Option` is either `Some` and contains a value, or `None`, and does not. | ||
* | ||
* ## Querying the variant | ||
* The `isSome` and `isNone` return `true` if the `Option` is `Some` or `None`, | ||
* respectively. | ||
* | ||
* @module | ||
*/ | ||
|
||
export { None, type Option, Some } from "./spec.ts"; | ||
export { | ||
filter, | ||
flat, | ||
map, | ||
mapOr, | ||
mapOrElse, | ||
zip, | ||
} from "./operators/transform.ts"; | ||
export { isNone, isSome } from "./operators/query.ts"; | ||
export { and, andThen, or, orElse, xor } from "./operators/logical.ts"; | ||
export { | ||
expect, | ||
match, | ||
type Matcher, | ||
unwrap, | ||
unwrapOr, | ||
unwrapOrElse, | ||
} from "./operators/extract.ts"; |