Closed alexlafroscia closed 5 years ago
This package is used by a few addons that have wider support matrixes/usage base, like ember-decorators, so I'm not sure if it'd be best to drop support entirely for babel 6 immediately. Would it be possible to support both at once? Or is it the same issue with @ember-decorators/argument
where we'd need to include different versions of the transform?
I would prefer to add 7 without dropping older Babel version support...
Would it be possible to support both at once
Totally! This should "just work" -- let me look into how to run the tests against both to make sure that support doesn't regress in the future.
I think swapping the ember-cli-babel version in ember-try config could work, but the discrepancies in the fixtures (that you had to fix here) will require some extra work (to assert against both Babel 6 and Babel 7)...
@rwjblue any tips on how to handle those differences in the fixtures?
I've seen other Babel plugins that support multiple versions have two versions of the fixtures -- maybe two versions of the fixtures? Two different test suites? Not sure what would be the best approach.
What I'm going to try right now (and seems to be working) is to duplicate the Node tests and have separate Babel 6 and 7 directories, and then configure ember-try
with 4 scenarios
The Ember tests really aren't anything right now, but if that ever changes this will handle it.
That sounds nice, thank you for keeping at it...
I'm not sure why, but my initial pass at getting the tests to pass against Babel 6 didn't work...
I started over, breaking up the changes into more sensible commits, and it seems to be all working now 🤷♂️
Thanks again for getting this over the line @alexlafroscia!
This change updates the addon to support Babel 7 (and
ember-cli-babel
) 7.This could be treated as a breaking change, or not. Technically,
babel-plugin-debug-macros
supports both Babel 6 and 7 (right now) and the custom plugin that's part of this addon didn't need to be changed at all to support Babel 7. I'm just not sure if you want to go about supporting both versions, or make a hard break now and just support Babel 7.Closes #24