wix-incubator / vscode-glean

The extension provides refactoring tools for your React codebase
MIT License
1.46k stars 56 forks source link

Stateful/stateless terminology #106

Closed jedwards1211 closed 4 years ago

jedwards1211 commented 4 years ago

Using "Stateful Component" to refer to React.Component classes and "Stateless Component" to refer to functional components is a vestige of the way React used to be, now that we have hooks both classes and functions can be stateful or stateless. Maybe consider switching to the terms "Class Component" and "Function Component"?

borislit commented 4 years ago

Hey @jedwards1211 !Thanks for the issue. Do you have hooks supported turned on? Once you have it activated, You will notice the terminology change. This is under the feature flag, as with pre-Hook React version "state" is actually the major difference between the class and function and it also helps communicate exactly what the extension will do (i.e remove any setState calls and refactor state references).