Scott Whittaker

Software Engineer

Day job React | side projects Svelte

React Stateless Components

An initial look at React stateless components. The docs call them Stateless Functions so it looks like I am wrong already! The terms do appear to be interchangeable though.

This is what the docs have to say about stateless functions…

This simplified component API is intended for components that are pure functions of their props. These components must not retain internal state, do not have backing instances, and do not have the component lifecycle methods. They are pure functional transforms of their input, with zero boilerplate. However, you may still specify .propTypes and .defaultProps by setting them as properties on the function, just as you would set them on an ES6 class.

React Docs

Examples