Skip to content

Instantly share code, notes, and snippets.

@thoughtpalette
Created September 16, 2015 16:12
Show Gist options
  • Select an option

  • Save thoughtpalette/efdec0a8993a3a36fa03 to your computer and use it in GitHub Desktop.

Select an option

Save thoughtpalette/efdec0a8993a3a36fa03 to your computer and use it in GitHub Desktop.

Revisions

  1. thoughtpalette created this gist Sep 16, 2015.
    11 changes: 11 additions & 0 deletions React Life Cycle Methods - Reference
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,11 @@
    Lifecycle Methods

    componentWillMount – Invoked once, on both client & server before rendering occurs.
    componentDidMount – Invoked once, only on the client, after rendering occurs.
    shouldComponentUpdate – Return value determines whether component should update.
    componentWillUnmount – Invoked prior to unmounting component.
    Specs

    getInitialState – Return value is the initial value for state.
    getDefaultProps – Sets fallback props values if props aren’t supplied.
    mixins – An array of objects, used to extend the current component’s functionality.