Created
April 11, 2017 08:59
-
-
Save shafiqshams/b221f32d9e67242279ec672dde49ed64 to your computer and use it in GitHub Desktop.
Refactored to Class Based Component.
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
import React, { Component } from 'react'; | |
import { Text, View } from 'react-native'; | |
class AlbumList extends Component { | |
render() { | |
return ( | |
<View> | |
<Text> AlbumList!!! </Text> | |
</View> | |
); | |
} | |
} | |
export default AlbumList; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Benefits of class based components, Unique advantage over functional components..
called LifeCycle Methods
In functional some data goes in and JSX comes out. but in ClassBased: which have alot more knowledge k kab render hona hai kab remove hona hai.. and notification can be received.
One of the LC method is componentWillMount()