Introduction to React.js | Lifecycle methods

Introduction to React.js | Lifecycle methods
Lifecycle methods:
  1. componentWillMount()

    :-
    It is called just before the render function is called
  2. componentDidMount()

    :-
    It is called just after the whole render() function is executed
  3. getDerivedSttaeFromProps()

    :-
    It is used to assign or update or delete state from props
  4. componentWillUnmount()

    :-
    This method is called just before the component is removed from the virtual DOM
  5. componentDidUpdate()

    :-
    Tjhis is ca;led whenever the state on ject is changed
  6. The

    constructor()

    , method is used to set the state variables and other normal properties of the com[ponent to defayult values which will be the initial values. It takes props as a single argument

Comments

Popular posts from this blog

Parallel Database design, query processing

Laravel | PHP | Basics | Part 2

Apache Hadoop | Running MapReduce Jobs