title: Requiring electron dialog from render process is undefined
body: <p>I am using electron and am trying to open a file browser when a user clicks on button. From the render process I am trying to include the elctron.dialog package like this.</p>
  
  <pre><code>const dialog = require( 'electron' ).dialog;
  
  console.log( dialog );
  </code></pre>
  
  <p>However the result from the console log is <code>undefined</code></p>
  
  <p>I am absolutely sure I am in the rendering process so I am not sure why this is not working. The documentation suggests that this is the correct way of doing things but it appears to not be working. </p>
  
  <p>This is my <code>package.json</code> file </p>
  
  <pre><code>{
    "name": "my-app",
    "version": "0.1.0",
    "main": "./main.js",
    "scripts": {
      "start": "electron ."
    },
    "dependencies": {
      "electron": "^0.4.1"
    }
  }
  </code></pre>
  
  <p>This is my <code>main.js</code> file</p>
  
  <pre><code>    'use strict';
  
      var app = require( 'app' );
      var BrowserWindow = require( 'browser-window' );
      var ipc = require( 'ipc' );
  
      var mainWindow = null;
  
      app.on(
          'ready', function () {
              mainWindow = new BrowserWindow(
                  {
                      frame : true,
                      height: 700,
                      width : 500
                  }
              );
  
              mainWindow.loadUrl( 'file://' + __dirname + '/app/index.html' );
  
              mainWindow.openDevTools();
              mainWindow.on(
                  'closed', function () {
                      mainWindow = null;
                  }
              );
  
          }
      );
  
      ipc.on(
          'close-main-window', function () {
              app.quit();
          }
      );
  </code></pre>
  
  <p>this is the rendered process file </p>
  
  <pre><code>    // Add your index.js code in this file
      var ipc = require( 'ipc' );
  
      const dialog = require( 'electron' ).dialog;
  
      console.log( dialog );
  </code></pre>
  
  <p>This is the console </p>
  
  <p><img src="https://www.dropbox.com/s/j2pnocwxfv4l8sb/Screenshot%202016-04-14%2019.25.08.png?dl=1" alt=""></p>
  
  <p>Is this incorrect?</p>