title: Cannot use import statement outside a module when importing a const from another js file
body: <p>I am developing a chrome extension.</p>
  
  <p>One of my js files contains a <code>const</code> object.</p>
  
  <p>I tried to import this from another <code>js</code> file in the same directory.</p>
  
  <blockquote>
    <p>Uncaught SyntaxError: Cannot use import statement outside a module</p>
  </blockquote>
  
  <p>In my <code>attributes.js</code></p>
  
  <pre><code>export const key_attributes = {
      'GK': ['Aerial', 'Agility', 'Handling', 'Reflexes'],
  }
  </code></pre>
  
  <p>I have the above</p>
  
  <p>In <code>table.js</code>, I have</p>
  
  <pre><code>import { key_attributes } from './attributes'
  </code></pre>
  
  <p>This gives me</p>
  
  <blockquote>
    <p>Uncaught SyntaxError: Cannot use import statement outside a module`</p>
  </blockquote>
  
  <p>Any help?</p>