title: What is the Client/Server model when using Electron (Atom Shell)?
body: <p>I'm trying to wrap my head around how <a href="https://github.com/atom/electron">Electron</a> (formerly Atom Shell) works.</p>
  
  <p>I'm coming from a traditional, MVC-style web application where a Browser is calling a <em>Controller Action</em> through a <em>Routing System</em>, the Controller then fetches data from a store (File System, Data Base, ...) and renders a <em>View</em>, which is sent back to the Browser. Some Actions may be sending back JSON instead, as they are called through JavaScript/AJAX instead of the Browser actually navigating to them.</p>
  
  <p>I want to create that, but as a Cross-Platform Desktop Application. I know that Atom Shell combines both a Chromium-Browser and a Node.js/v8 runtime, but I'm not sure how they would communicate.</p>
  
  <p>I guess I could run a full on web server (basically, some Node.js HTTP Middleware like <a href="http://expressjs.com/">Express</a>), but that creates a network-reachable server (which might also trip up firewalls) - one of the reasons I want to make a desktop app is precisely to avoid running a real server. Basically like the MVP/MVVM pattern in a "normal" desktop app.</p>
  
  <p>Can someone give me a few starting points for what I'm trying to do? How would the browser talk to the node runtime (the "Client" as they call it?) to tell it "Hey, fetch my the record with ID 12345" and would the Client return rendered HTML, or would the browser just get a blob of JSON back and render it through a JavaScript templating engine?</p>