So I have these two files:
foo1
const a = 2;
export {a};
and
foo2
import a from "./foo1.js";
console.log(a);
both files have been made module files with the html:
<script src='./scripts/foo2.js' type='module'></script>
<script src='./scripts/foo1.js' type='module'></script>
As soon as the script runs it throws this error:
Uncaught SyntaxError: The requested module './foo2.js' does not provide an export named 'default'