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

x/ddc_vim/deps.ts>Lock#lock

Dark deno-powered completion framework for neovim/Vim8
Very Popular
Go to Latest
method Lock.prototype.lock
import { Lock } from "https://deno.land/x/ddc_vim@v3.9.0/deps.ts";

Acquires the lock and applies the given function to the shared value, returning the result.

Parameters

f: (value: T) => R | PromiseLike<R>
  • The function to apply to the shared value.

Returns

Promise<R>

A Promise that resolves with the result of the function.