JSProxy constructor
Creates a new JS proxy for a target.
C#
public JSProxy(JSObject jsTarget, Handler handler, object? target = null, bool revocable = false)
parameter | description |
---|---|
jsTarget | JS target for the proxy. |
handler | Proxy handler callbacks (traps). |
target | Optional target object to be wrapped by the JS target, or null if the JS target will not wrap anything. |
revocable | True if the proxy may be revoked; defaults to false. |
Remarks
If a wrapped target object is provided, proxy callbacks my access that object by calling Unwrap
.
See Also
- struct JSObject
- class Handler
- struct JSProxy
- namespace Microsoft.JavaScript.NodeApi