title: Can't figure out how to import modules in browser with javascript
body: <p>This is a simple problem. I'm attempting to import modules from one javascript file to another, and then run it on Chrome. I'm using 2 javascript files and an html file, all in the same folder:</p>
  
  <p>first js file (testfile1.js):</p>
  
  <pre><code>import {test} from 'testfile2.js';
  
  test.func();
  </code></pre>
  
  <p>second js file (testfile2.js):</p>
  
  <pre><code>let f = function() {
    console.log("TEST");
  }
  
  let test = {
    func: f
  };
  
  export test;
  </code></pre>
  
  <p>The html file is plain, empty html file with a link to testfile1.js script in the header:</p>
  
  <pre><code>&lt;script type="text/javascript" src="testfile1.js"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>Whenever I open the html file in chrome, I get the error:</p>
  
  <pre><code>testfile1.js:1 Uncaught SyntaxError: Unexpected token {
  </code></pre>
  
  <p>When I removed the brackets in the import statement, I get an unexpected identifier statement. Isn't this the proper way to import modules in the browser? Why is it not working at all?</p>