Skip to content
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

PR: Electron Interop #1

Open
frank-dspeed opened this issue Oct 25, 2022 · 0 comments
Open

PR: Electron Interop #1

frank-dspeed opened this issue Oct 25, 2022 · 0 comments

Comments

@frank-dspeed
Copy link
Member

frank-dspeed commented Oct 25, 2022

PR: Electron Interop

Electron has a -e flag to eval code when stdio is supported on windows for example that is not the case there exist electron issues how ever the most cross platform compilant way is to expose a repl server via namedPipe which is possible in all Platforms more or less efficent but possible.

So we need to create a electron-repl as also a electron-named-pipe implementation we should not implement handle based RPC here while it looks promising it would only add overhead we need to wait for a real use case at present i think the repl pipe protocol is more well then the handle based protocol that is used inside chromium called devtools. It simply exists because we got no more direct way to interface with the rest of the components.

Usage example

main.js

//import('modules-repl').then((ReplModules)=>ReplModules.baseUrl.set('')) if you need to modify the baseUrl to get something working on your platform or in your case. else the defaults should near always work under default conditions.
import('modules-repl').then((ReplModules)=>RepelModules.electron.main('nameOfthePipe'));

with stealify we should create a MainTask Component that uses the electron.main method or something diffrent maybe no time to think about that at present lets finish this PR first.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant