ember-codemods / ember-tracked-properties-codemod

A codemod for transforming your ember app code to start using `@tracked` properties.
MIT License
8 stars 3 forks source link

Convert the `setters` into standard JS syntax #43

Open suchitadoshi1987 opened 4 years ago

suchitadoshi1987 commented 4 years ago

Convert simple cases of setters into standard JS syntax.

// Before
let chad = Person.create();
chad.set('firstName', 'Chad');
chad.set('lastName', 'Hietala');

// After
let chad = new Person();
chad.firstName = 'Chad';
chad.lastName = 'Hietala';
rajasegar commented 4 years ago

@suchitadoshi1987 Is someone working on this?

suchitadoshi1987 commented 4 years ago

@rajasegar not at the moment, feel free to pick it up if you have some bandwidth :)

rajasegar commented 4 years ago

OK I will pick it up then.

rajasegar commented 4 years ago

You have also replaced create with new expression in your example, it is not part of the conversion right?