Profectus / util/proxies / createLazyProxy
Function: createLazyProxy() ​
createLazyProxy<
T,S>(objectFunc,baseObject):T&S
Makes a lazily evaluated object through the use of a Proxy
Type Parameters ​
• T extends object
• S extends object
Parameters ​
objectFunc ​
(this, baseObject) => T
Function that constructs the object to be proxies
baseObject ​
S = ...
An optional base object to pass to objectFunc, which all return properties will be assigned onto
Returns ​
T & S
A proxy for the object created by objectFunc