Latest
function default
import { default } from "https://dotland.deno.dev/x/lodash_es@v0.0.2/src/defaultTo.js";

Checks value to determine whether a default value should be returned in its place. The defaultValue is returned if value is NaN, null, or undefined.

Examples

_.defaultTo(1, 10); // => 1

_.defaultTo(undefined, 10); // => 10

Parameters

value

The value to check.

defaultValue

The default value.