cityofaustin/janis

Refactor React components to stateless functions

mateoclarke opened this issue · 2 comments

We have a few components that aren't making use of React's component state or lifecycle methods. These components should be refactored to use the stateless functional pattern if they are purely for rendering DOM elements and not managing state. This will improve performance and clean up our code.

more info: https://tylermcginnis.com/functional-components-vs-stateless-functional-components-vs-stateless-components/

We've already been doing this as we go back through and touch the file in question, but just read another article that makes the case about why this is good:
http://reactingonrails.com/prefer-functional-components/

Closing as all current components that should be stateless are.