galkinrost / react-lifecycle-decorators

Decorators for stateless components
MIT License
13 stars 0 forks source link

whats use case for this decorators? #1

Open stepancar opened 8 years ago

galkinrost commented 8 years ago

In our team we use this decorators to implement lifecycle methods for stateless components

stepancar commented 8 years ago

@galkinrost , what reasons to use lifecycle methods in stateless components? Can you provide any not syntetic example? As i understand, good example - usage componentDidMount for bind any plugin to Dom. Could you please share another cases?

galkinrost commented 8 years ago

The most popular case for us is a prefetching data for view at the componentWillMount state.