title: Require() is not defined in electron - node js
body: <p>I am using electron with node js. I have used require() already in two html files like this:</p>
  
  <pre><code>&lt;script&gt;
          window.$ = window.jQuery = require("jquery");
  &lt;/script&gt;
  </code></pre>
  
  <p>Now when I try to do the same thing in another html file in the same project, I get "ReferenceError: require is not defined" when the page loads. This other page is being shown in an iframe, but I'm not sure that would matter. </p>
  
  <p>And for reference I have set nodeIntegration to true in main.js.</p>
  
  <pre><code>webPreferences: {
    preload: path.join(__dirname, 'preload.js'),
    nodeIntegration: true
  }
  </code></pre>
  
  <p>Why would it allow me to use require() in a script on two html files, but not this new one?</p>