Using of ES6 modules trouble

Hello.

I have error window when run my test project with es6 modules with text:

Page 'http://localhost:63342/importTest/module.js' requested without authorization,
you can copy URL and open it in browser to trust it.

And there are two buttons: copy url.. and no

So in my case I don't need copy module url and paste it to address bar.

Project consists of three files: index.html, main.js used as script with type="module" and I need two import function from module.js in main.js by construction:

import {hello} from './module.js';

It works fine on my apache server. Without webpack. Just three files.

I have trouble only working with localhost server in Webstorm.

0
2 comments

Try enabling Allow unsigned frequests in Settings | Build, Execution, Deployment | Debugger - does it help?

1
Avatar
Permanently deleted user

Yep. It works now. Simple as the whole IDE. It's time to put modules in production!
Thank you!

1

Please sign in to leave a comment.