New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JSRuntime should have <JavascriptRef> #1775

christoph68 opened this Issue Jan 17, 2019 · 0 comments


None yet
1 participant
Copy link

christoph68 commented Jan 17, 2019

It would be great to have something like JavascriptRef.

Often interop code is awkward because no references to JS classes are possible. There needs to be a static function that does then identify the instance to be used/called.

a reference could be obtained like:
JavascriptRef jsRef =JSRuntime.Current.GetReference("JSFuncGet", args);

and then re-used:
JSRuntime.Current.InvokeAsync(jsRef , "JSFuncCall", args)

It seems that should be possible to achieve?
It surely would ease build wrappers around existing JS libs/components.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment