Someone asked a similar question last month and they were linked to this post. In that post it was basically stated that all code should go in the renderer process. And apparently this can be done easily: file system operations, calling things with
child_process.exec, accessing the app global variable directly (well really through
electron.remote), and all the cool node.js modules are available.
This surprised me because I saw the renderer process as existing in a “browser” like chrome or something, meaning you can’t access the computer system itself, just the DOM, but apparently this isn’t the case!
So my question is this, what exactly does the main process do? Because it seems all my logic and scripts and such can be moved to the renderer side and the only thing that needs to go in the
main.js file is the boilerplate code from the quickstart.
Also, is there any in depth reading on the underlying architecture of electron short of the source code? I’m curious about how everything is really tied together under the hood (and I suspect this will answer most future questions like this I may have).