title: Electron desktop app - load url by passing parameters - javascript
body: <p>I want to authenticate user with custom URL schema in which the link looks like this</p>
  
  <pre><code>appName://https://www.sitename.com/user-token
  </code></pre>
  
  <p>I implemented custom url successfully in info.plist file so that when clicking <strong>appName://</strong> open my destop app.</p>
  
  <p>My loadURL code looks like this in <strong>app.js</strong></p>
  
  <pre><code>mainWindow.loadUrl('http://www.sitename.com/', {
          userAgent: 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.52 Safari/537.36'
      });
  </code></pre>
  
  <p>Now how can i change the URL when the user clicks this</p>
  
  <pre><code>&lt;a href="appName://https://www.sitename.com/user-token"&gt;Open App&lt;/a&gt;
  </code></pre>
  
  <p>Any help?</p>