title: Use an exported JS function in another JS file
body: <p>I have the following structure in my project:</p>
  
  <p>--> map<br>
  ----> map.js<br>
  ----> cell.js</p>
  
  <p>The map.js is responsible for creating a 2D array which each position is a Cell object (cell.js).</p>
  
  <p>In my cell.js I have the code below:</p>
  
  <pre><code>export function Cell(x, y, w) {}
  </code></pre>
  
  <p>and in my map.js, when iterating on each position I create a new instance, like the example below:</p>
  
  <pre><code>import { Cell } from './cell.js';
  ...
  board[i][j] = new Cell(i, j, w);
  ...
  </code></pre>
  
  <p>And finally, in my index.html I just declare both of the scripts in the head tag:</p>
  
  <pre><code>...
  &lt;head&gt;
   &lt;script src="map/cell.js"&gt;&lt;/script&gt;
   &lt;script src="map/map.js"&gt;&lt;/script&gt;
  &lt;/head&gt;
  </code></pre>
  
  <p>When I open the index.html (double-click in the file) on Google Chrome, it shows me the following errors in the console:</p>
  
  <p><strong>Uncaught SyntaxError: Unexpected token export (cell.js:1)</strong><br>
  <strong>Uncaught SyntaxError: Unexpected token { (map.js:1)</strong></p>
  
  <p>What do I need still to do to be able to use both the Javascript functions?</p>