title: Sharing variables through files with webpack
body: <p>I have 2 js files.
  First file:</p>
  
  <pre><code>var object1 = {
      foo: 'bar'
  }
  </code></pre>
  
  <p>Second file</p>
  
  <pre><code>var object2 = {
      foo2: 'bar2'
  }
  console.log(object1.foo);
  </code></pre>
  
  <p>These 2 files are build with webpack to bundle.js file.
  But in this case I have troubles - object1 variable is not defined.</p>
  
  <p>I analyzed code in bundle.js file - webpack create for every file anonymous function - and I understand why I have error.</p>
  
  <p>It's possible do with webpack or not ?</p>
  
  <p>Off course I can use this variable as global variable, but I think - it's not a good idea.</p>