yandex / mapsapi-modules

Async modular system
132 stars 29 forks source link

Troubles with babel #49

Closed qfox closed 9 years ago

qfox commented 9 years ago

We have to:

require('babel/register');
require('desktop.bundles/main-app/main-app.js');

But, after babelifying code of ym we got undefined instead of this in global context because of new spec. The last line with this becomes:

})(undefined); // oops ;-(

Can we fix that somehow?

Ref: https://babeljs.io/docs/faq/#why-is-this-being-remapped-to-undefined-

narqo commented 9 years ago

:+1:

qfox commented 9 years ago

@dfilatov Thanks for publishing!