react-webpack-generators / generator-react-webpack

Yeoman generator for ReactJS and Webpack
http://newtriks.com/2013/12/31/automating-react-with-yeoman-and-grunt/
MIT License
2.88k stars 355 forks source link

Option to use React.createClass #285

Closed jordyvandomselaar closed 7 years ago

jordyvandomselaar commented 8 years ago

I'd like to have a setting that allows me to use React.createClass rather than extends. Would this be ok?

weblogixx commented 8 years ago

Hi @jordyvandomselaar,

this would be possible. If there is enough demand we we could maybe implement it into the next major version of the generator. @sthzg: Whats your opinion on this?

sthzg commented 7 years ago

Sorry for the late reply, somehow I missed that one. IMO that is a tough call. I can see how and why it would be valuable, on the other hand it would double the variations on the template generation and on the automated tests. Especially manually testing each possibility would become even more involved than it is already.

Also it may be worth thinking about consequences for external generators like the alt and flux generator, which had to add support as well. I also figure that sometimes there might not always be an easy path to support both worlds.

jordyvandomselaar commented 7 years ago

No problem :) I see, I'll just get used to it then, it's too much work for something that's not a must have to begin with. Thanks for the replies! :D

weblogixx commented 7 years ago

After thinking a bit longer about this, we will currently not implement this feature. Most projects move away vom React.createClass anyways. If the question arises again, we may have another look at it...