title: Chrome Extension - Pass URL argument (google-chrome http://www.google.com)
body: <p>I've developed a chrome extension/kiosk app that opens up Google Chrome in a "kiosk mode" with 4 navigation buttons, HOME, RELOAD, BACK and FORWARD. So it's basically an application that opens up Chrome in a window without Omnibox but added 4 buttons.
  This is because the user should not be able to change URL or anything else. Just navigate via the web interface and the 4 simple buttons.</p>
  
  <p>Now, this application/extension is packed with a hardcoded URL. Which means you can't change the URL.</p>
  
  <p>in my browser.html I have the following code:</p>
  
  <pre><code>&lt;webview src="http://www.example.com/" style="width:100%; height:100%"&gt;&lt;/webview&gt;
  </code></pre>
  
  <p>and in my browser.js I have the following code:</p>
  
  <pre><code>document.querySelector('#home').onclick = function() {
  navigateTo('http://www.example.com/');
  };
  </code></pre>
  
  <p>As you can see the URL is hardcoded both in HTML file and the javascript file.</p>
  
  <p>My question is. Can I change the URL so it's not hardcoded in the extension/kiosk app?
  So if I type <code>google-chrome --app-id="jlfmnfhdcdmkibjnbeajhedeoahajnfc" http://www.google.com</code>
  into a terminal or cmd, I would want google.com to be displayed.</p>
  
  <p>There may be a simple solution or no solution at all. This is my first attempt at making a chrome extension/kiosk app. So I'm an amateur in this area.</p>
  
  <p>If you want to take a look at the source code, then you can find it on <a href="https://github.com/HeadlessChild/chrome-kiosk" rel="nofollow noreferrer">github</a>. </p>