File tree 2 files changed +14
-10
lines changed
Libraries/CustomComponents/ListView
2 files changed +14
-10
lines changed Original file line number Diff line number Diff line change @@ -56,10 +56,10 @@ var DEFAULT_SCROLL_CALLBACK_THROTTLE = 50;
56
56
/**
57
57
* ListView - A core component designed for efficient display of vertically
58
58
* scrolling lists of changing data. The minimal API is to create a
59
- * `ListView.DataSource`, populate it with a simple array of data blobs, and
60
- * instantiate a `ListView` component with that data source and a `renderRow`
61
- * callback which takes a blob from the data array and returns a renderable
62
- * component.
59
+ * [ `ListView.DataSource`](docs/listviewdatasource.html) , populate it with a simple
60
+ * array of data blobs, and instantiate a `ListView` component with that data
61
+ * source and a `renderRow` callback which takes a blob from the data array and
62
+ * returns a renderable component.
63
63
*
64
64
* Minimal example:
65
65
*
@@ -117,7 +117,9 @@ var ListView = React.createClass({
117
117
*/
118
118
propTypes : {
119
119
...ScrollView . propTypes ,
120
-
120
+ /**
121
+ * An instance of [ListView.DataSource](docs/listviewdatasource.html) to use
122
+ */
121
123
dataSource : PropTypes . instanceOf ( ListViewDataSource ) . isRequired ,
122
124
/**
123
125
* (sectionID, rowID, adjacentRowHighlighted) => renderable
Original file line number Diff line number Diff line change @@ -107,12 +107,13 @@ function isRunnable(componentName, componentPlatform) {
107
107
108
108
// Hide a component from the sidebar by making it return false from
109
109
// this function
110
- function shouldDisplayInSidebar ( componentName ) {
111
- if ( componentName === 'Transforms' ) {
112
- return false ;
113
- }
110
+ var HIDDEN_COMPONENTS = [
111
+ 'Transforms' ,
112
+ 'ListViewDataSource' ,
113
+ ] ;
114
114
115
- return true ;
115
+ function shouldDisplayInSidebar ( componentName ) {
116
+ return HIDDEN_COMPONENTS . indexOf ( componentName ) === - 1 ;
116
117
}
117
118
118
119
function getNextComponent ( i ) {
@@ -271,6 +272,7 @@ var apis = [
271
272
'../Libraries/LayoutAnimation/LayoutAnimation.js' ,
272
273
'../Libraries/Linking/Linking.js' ,
273
274
'../Libraries/LinkingIOS/LinkingIOS.js' ,
275
+ '../Libraries/CustomComponents/ListView/ListViewDataSource.js' ,
274
276
'../node_modules/react/lib/NativeMethodsMixin.js' ,
275
277
'../Libraries/Network/NetInfo.js' ,
276
278
'../node_modules/react/lib/PanResponder.js' ,
You can’t perform that action at this time.
0 commit comments