i am trying to start using es6 module with help of systemjs and babel:
index.js
import mod from 'page/mod';
console.log(mod);
mod.js
export default {
a=1
, b=2
}
syntax error is obvious (i ve used =, but should :)
Chrome and Firefox kindly show this error in console:
Uncaught (in promise) Error: http://localhost:9092/assets/ff71b75f/mod.js: Unexpected token (2:7)
1 | export default {
> 2 | a=1
| ^
3 | , b=2
4 | }
Error loading http://localhost:9092/assets/ff71b75f/mod.js as "page/mod" from http://localhost:9092/assets/e8e4f277/index.js
at t (http://localhost:9092/jspm_packages/system.js:4:61)
at g (http://localhost:9092/jspm_packages/system.js:4:9914)
at http://localhost:9092/jspm_packages/system.js:4:8054
but Safari show nothing.
After some research my guess is that it has something to do with the fact that systemJS uses promises to asynchronously load modules. But all problems that i found about debugging promises is dated about 2014 and people suggest to include BlueBird thing that fixes error silencing.
Is this advice right for modern Safari? Or i can do something without including additional scripts?