emberjs / ember-cli-babel

Ember CLI plugin for Babel
MIT License
153 stars 120 forks source link

Not working with addon #13

Closed jclem closed 9 years ago

jclem commented 9 years ago

With a new add-on generated from Ember CLI v0.1.12, simply running npm install --save-dev ember-cli-6to5 as the readme states does not run the add-on code through 6to5. Is there an extra step for Ember CLI add-ons?

stefanpenner commented 9 years ago

issue with ember-cli add ons. WIP solution: https://github.com/ember-cli/ember-cli/pull/3166

jclem commented 9 years ago

Yeah, just saw that (https://github.com/ember-cli/ember-cli/issues/2354). Bummer.

jclem commented 9 years ago

@stefanpenner BTW, updating the readme with this info might be useful. I spent about 20 minutes thinking I was doing something wrong before I opened this.

stefanpenner commented 9 years ago

@jclem its possible, but a-bit tricky. I have this working in my app, by overriding compileAddon in my add-on.

Please note, this is clearly shitty and pretty well unsupported, hence @lukemelia's work to make this work correctly with-out gotchas

Something like allows my to "make it work": screen shot 2015-02-04 at 3 21 48 pm

jclem commented 9 years ago

Thanks, @stefanpenner I'll try that out in the meantime.

stefanpenner commented 9 years ago

Thanks, @stefanpenner I'll try that out in the meantime.

you do so at your own risk ;)

stefanpenner commented 9 years ago

@lukemelia's work will allow deeply nested add ons to correctly attach their own filters and transpilers. It will be nice :)

lukemelia commented 9 years ago

That PR is getting close. @jclem if you want to help out, you could help with one of the outstanding tasks in the checklist.

jclem commented 9 years ago

@lukemelia I've never looked into Ember CLI's internals at all, actually :\ I'll take a look at it if I have some time. If not, I'm perfectly happy being patient :)

DougPuchalski commented 9 years ago

Can anybody confirm this is still pending as of 0.2.0?

rwjblue commented 9 years ago

@aceofspades - using babel in an addon works properly under ember-cli 0.2.0

DougPuchalski commented 9 years ago

@rwjblue Thanks for confirming, oddly modules in addon are definitely not getting transpiled. Assuming it should be automatic w/default config... Will dig further.

stefanpenner commented 9 years ago

Modules don't get compiled with babel we use Esperanto for thst

DougPuchalski commented 9 years ago

@stefanpenner Are you saying something different happens for addons? I'm finding the various steps and recent changes confusing, not sure how up to date the docs are

stefanpenner commented 9 years ago

@stefanpenner Are you saying something different happens for addons? I'm finding the various steps and recent changes confusing, not sure how up to date the docs are

nope, everything should be the same. babel handles es syntax except for modules, esperanto handles modules

DougPuchalski commented 9 years ago

@stefanpenner Just created an issue per fail https://github.com/ember-cli/ember-cli/issues/3556