Options
All
  • Public
  • Public/Protected
  • All
Menu

Class GlobalRegistry

A convenient class to manage global variables.

Hierarchy

  • GlobalRegistry

Index

Constructors

Properties

Methods

Constructors

constructor

Properties

Protected Readonly storage

storage: AsyncLocalStorage<Collection<GlobalRegistrant>> = ...

Methods

Protected getCollection

getGlobal

  • getGlobal(key: string | symbol): any
  • Retrieve the value of the given key, if it exists in the store.

    Parameters

    • key: string | symbol

    Returns any

run

  • run<T>(closure: () => T): T
  • Run a closure with a global registry.

    Type parameters

    • T

    Parameters

    • closure: () => T
        • (): T
        • Returns T

    Returns T

setGlobal

Extollo Logo

extollo (v. latin) - to lift up, to elevate

Extollo is a free & libre application framework in TypeScript.