Closed gurkerl83 closed 8 years ago
Great idea, but maybe you can first proposal to @chentsulin's electron-react-boilerplate. :D Although I think this is different purpose, maybe we need to create a new repo.
Hey, @gurkerl83. I plan to add support to Electron similarly to Chrome apps, and even tested that a bit. We use chrome messaging only for communicating with content (injected) script, which is the case only for extensions. We do not use it even fro Chrome apps. I do not see any problems for supporting Electron, we may even use a main store as for extensions and implement it through remote.getGlobal
, though I'm still not sure we need it there unless we have several windows.
I'll look into the N1 example, the boilerplate suggested @jhen0409 is awesome, I played with it before.
Implemented in 0.6
. Also, we have an example of building apps only.
Hi, first of all browser-redux sounds like a working concept which allows state synchronisation throughout multiple sandboxed environments such as content and background scripts in the browser. Electron has a similar structure which separates main and render aspects. Unfortunately Electron does not support chrome API`s so a direct reuse of browser-redux and the underlying libraries such as crossmessaging is not possible. On the other hand Electron implements a nice IPC and remote - require concept which would allow a port of browser-redux. Note: N1 implements a action-bridge which is backed by Electron IPC allowing to dispatch Actions within a window, global and work environment scope.
https://github.com/nylas/N1/blob/master/src/flux/action-bridge.coffee
Thanks