JavaScript module on browser [duplicate]
问题 This question already has answers here : Access to Image from origin 'null' has been blocked by CORS policy (8 answers) Closed 4 hours ago . catalog - folder - index.html - index.js - index1.js index.html <!-- main content ---> <script type='module' src='./index.js'></script> index.js import {show} from "./index1" show(); index1.js export default function show(){ console.log('hello world'); } descripttion when run index.html on browser, is don't work, and i got this error: Access to script at