title: TypeError: Cannot read property 'setZoomLevelLimits' of undefined
body: <p>I ran into the following error after trying to start my electron app via <code>npm start</code>. Here's the error message:</p>
  
  <blockquote>
    <p><code>TypeError: Cannot read property 'setZoomLevelLimits' of undefined</code></p>
  </blockquote>
  
  <p>Below is the code:</p>
  
  <pre><code>const electron = require("electron").webFrame.setZoomLevelLimits(1, 1);
  const app = electron.app;
  const BrowserWindow = electron.BrowserWindow;
  
  
  let mainWindow;
  
  app.on("ready", function(){
    mainWindow = new BrowserWindow({
      width: 800,
      height: 600,
      frame: false,
      kiosk: true
    });
  
    mainWindow.loadURL("file://" + __dirname + "/index.html");
  
    // Debug3
    // mainWindow.openDevTools({ detach: true });
  });
  </code></pre>
  
  <p>I am trying to prevent user for dragging and zooming in the screen on my desktop app, and <code>website-user-drag: none</code> doesn't work as well as this:</p>
  
  <pre><code>&lt;meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height, target-densitydpi=device-dpi" /&gt;
  </code></pre>