title: fs.writeFile is not a function in angular2+electron
body: <p>I have electron + angular2 project.</p>
  
  <p>I need to create file and save it locally after user registers.</p>
  
  <p>In my register.component.ts file I'm trying to use </p>
  
  <pre><code>        import fs = require('fs');
          ...
          fs.writeFile(filename, content, (err) =&gt; {
          if (err) {
              alert("An error ocurred creating the file " + err.message)
          }
  
          alert("The file has been succesfully saved");
      });
  </code></pre>
  
  <p>I've installed node types and added</p>
  
  <pre><code>    node: {
      fs: "empty"
      },
  </code></pre>
  
  <p>To webpack.common.js file.</p>
  
  <p>Now I'm getting</p>
  
  <blockquote>
    <p>ERROR TypeError: fs.writeFile is not a function</p>
  </blockquote>
  
  <p>Any ideas what might cause that?</p>