Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

isSome

import { isSome } from "https://raw.githubusercontent.com/baetheus/fun/main/option.ts";

Tests wether an Option is Some, returning true if the passed option is Some and false if it is None.

@example
import * as O from "./option.ts";

const result1 = O.isSome(O.none); // false
const result2 = O.isSome(O.some(1)); // true
function isSome<A>(m: Option<A>): m is Some<A>;
§
isSome<A>(m: Option<A>): m is Some<A>
[src]

§Type Parameters

§Parameters

§Return Type

§
m is Some<A>
[src]