expose
Expose a value to a global namespace path. Existing values are preserved unless overwrite is explicitly set.
Usage
import { expose } from "@olenbetong/appframe-core";
function hello() {
console.log("Hello");
}
expose("MyApp.hello", hello);API
export declare function expose(
name: object | string,
value:
| object
| ((...args: any[]) => any)
| ((...args: any[]) => any)[]
| string
| number,
options?: { overwrite?: boolean },
): void;Last updated
Was this helpful?