Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

stateless vs stateful components in react

STATEFUL COMPONENTS
->These are also known as-Class-based or
Container or Smart components.
->These haveastate object.
->These keepatrack of changing data via
the state object.

                             STATELESS COMPONENTS
                        -> These are also known as Function-based
                          or Presentational or Dumb components.
                        -> These do not haveastate object.
                        -> These print out what is given to them via
                         props,or they always render the same
                         thing.
 
PREVIOUS NEXT
Tagged: #stateless #stateful #components #react
ADD COMMENT
Topic
Name
9+8 =