lundi 31 août 2015

ES6 Import Folder

Does the ES6 module syntax allow you to import something from a folder?

For example if I have ./sub/main.js and I try import foo from './sub in the ./main.js file, will this work?

Could I get this sort of importing from a folder to work with babel and webpack?

Basically this would be the equivalent of __init__.py in Python.



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire