Presentational and Container Components
Dan Abramov

Hi, thanks for writing this very clear article. I’m learning react and one thing about this pattern I’m still fuzzy on is where event listeners and event logic should reside…in the presentational component or container component? As a simple example, let’s say I have an image carousel. It has several components: its container, next/previous buttons, the images, etc. Which component type handles listening for clicks or dragging? Which handles the logic for what to do when you reach the end of the carousel, etc? Thanks to anyone who can shed some light on this.

One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.