Module

x/lodash_es/src/function.js>once

lodash for deno use
Latest
function once
import { once } from "https://dotland.deno.dev/x/lodash_es@v0.0.2/src/function.js";

Creates a function that is restricted to invoking func once. Repeat calls to the function return the value of the first invocation. The func is invoked with the this binding and arguments of the created function.

Examples

var initialize = _.once(createApplication); initialize(); initialize(); // => createApplication is invoked once

Parameters

func

The function to restrict.