Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Functional component style for presentational components #19

Closed
sampl opened this issue Jul 22, 2017 · 7 comments
Closed

Functional component style for presentational components #19

sampl opened this issue Jul 22, 2017 · 7 comments
Labels

Comments

@sampl
Copy link
Owner

sampl commented Jul 22, 2017

https://medium.com/@dan_abramov/smart-and-dumb-components-7ca2f9a7c7d0

File structure: flat folders for layout, pages, presentational?

@sampl sampl added the soon label Jul 23, 2017
@sampl
Copy link
Owner Author

sampl commented Jul 28, 2017

Include proper componentWillUnmount listeners and turn off listeners to prevent "cannot setstate of unmounted component" errors on top-level pages

@sampl
Copy link
Owner Author

sampl commented Jul 28, 2017

what about PostLiker? not a page...

@sampl
Copy link
Owner Author

sampl commented Jul 30, 2017

Idea: components are either containers or presentational UI, but they live in folders grouped by feature, not component type

@sampl
Copy link
Owner Author

sampl commented Aug 1, 2017

not going to have strict separation in directories, but it's probably worth using simpler function react component syntax for the presentational ones eventually

@sampl sampl added next and removed maybe labels Aug 3, 2017
@sampl
Copy link
Owner Author

sampl commented Aug 4, 2017

@sampl
Copy link
Owner Author

sampl commented Aug 4, 2017

on second thought, this hurts readability for new es6/react devs, and does it really help?

@sampl sampl added maybe and removed next labels Aug 4, 2017
@sampl sampl changed the title Separate page-level components Functional component style for presentational components Aug 4, 2017
@sampl
Copy link
Owner Author

sampl commented Aug 6, 2017

very few pure presentational components in the boilerplate anyway, closing

@sampl sampl closed this as completed Aug 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant