A few words about ReactJS components

ReactJS components

Written by burczu

  • Martin Schayna

    Well, that’s why Redux or other similar projects should be used in a huge application, logic is separated and components are connected to handle changes in the model.

    • Of course, Flux architecture may help you to separate part of the logic (related to the state of the whole app) but components will still have their own logic related to its own state…

      • Martin Schayna

        Sure, but state in compinents should be minimized as much as possible, see the difference in Redux “connected” and “dumb” components, the state is in the store and it is passed to components via props only. Need of render should be highly optimized via pure render and Reselect.

        • Yes, the state is in store, however it’s only application state (I hope you do it this way) – components may have its own state used for UI manipulations etc., so they have still its own logic inside which will likely grow in bigger apps…