Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/ts_matches/src/parsers/parser.ts>Parser#defaultTo

Being able to pattern match in typescript
Go to Latest
method Parser.prototype.defaultTo
import { Parser } from "https://deno.land/x/ts_matches@v5.2.1/src/parsers/parser.ts";

There are times that we would like to bring in a value that we know as null or undefined and want it to go to a default value

Parameters

defaultValue: C