GavinJoyce / babel-plugin-remove-functions

Remove function based on configuration
MIT License
1 stars 1 forks source link

Support nested destructuring? #19

Open GavinJoyce opened 8 years ago

GavinJoyce commented 8 years ago

This addon supports simple destructuring but doesn't yet support nested destructuring such as:

const { run: { later }} = Ember;

I'm not sure that this type of destructuring is good practice, it seems pretty unreadable to me. I also haven't yet come across an ember app which uses this form. Also, the main motivation for this plugin to address https://github.com/ember-cli/rfcs/pull/50 which doesn't include any nested functions.

GavinJoyce commented 8 years ago

Hmm. I found a case where we use this style in ember-cli:

https://github.com/ember-cli/ember-cli/blob/master/blueprints/app/files/tests/helpers/module-for-acceptance.js#L6

screen shot 2016-11-17 at 09 53 40