Last active
August 29, 2015 14:22
-
-
Save bliaxiong/a377d1d8887eab97405d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var React = require('react'); | |
var Example = React.createClass({ | |
// | |
propTypes: function() { | |
}, | |
displayName: function() { | |
}, | |
getInitialState: function() { | |
}, | |
getDefaultProps: function() { | |
}, | |
render: function() { | |
return ( | |
<div /> | |
); | |
} | |
// Lifecycle Methods - Mounting | |
componentDidMount: function() { | |
// Do AJAX here for data | |
}, | |
componentWillUnmount: function() { | |
}, | |
// Lifecycle Methods - Updating | |
componentWillReceiveProps: function() { | |
}, | |
shouldComponentUpdate: function() { | |
}, | |
componentWillUpdate: function() { | |
}, | |
componentDidUpdate: function() { | |
}, | |
componentWillUnmount: function() { | |
} | |
}); | |
module.exports = Example; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment