mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-23 20:01:01 +08:00
debug overlay
Reviewed By: yungsters Differential Revision: D4534822 fbshipit-source-id: ceef5bc5c0dc8cdc0d3927e198273b4411045bde
This commit is contained in:
committed by
Facebook Github Bot
parent
12b228c5d9
commit
0a86c1cb15
@@ -52,6 +52,7 @@ class FlatListExample extends React.PureComponent {
|
||||
|
||||
state = {
|
||||
data: genItemData(1000),
|
||||
debug: false,
|
||||
horizontal: false,
|
||||
filterText: '',
|
||||
fixedHeight: true,
|
||||
@@ -90,6 +91,7 @@ class FlatListExample extends React.PureComponent {
|
||||
{renderSmallSwitchOption(this, 'horizontal')}
|
||||
{renderSmallSwitchOption(this, 'fixedHeight')}
|
||||
{renderSmallSwitchOption(this, 'logViewable')}
|
||||
{renderSmallSwitchOption(this, 'debug')}
|
||||
</View>
|
||||
</View>
|
||||
<FlatList
|
||||
@@ -98,6 +100,7 @@ class FlatListExample extends React.PureComponent {
|
||||
ItemComponent={this._renderItemComponent}
|
||||
SeparatorComponent={SeparatorComponent}
|
||||
data={filteredData}
|
||||
debug={this.state.debug}
|
||||
disableVirtualization={!this.state.virtualized}
|
||||
getItemLayout={this.state.fixedHeight ? this._getItemLayout : undefined}
|
||||
horizontal={this.state.horizontal}
|
||||
@@ -105,9 +108,9 @@ class FlatListExample extends React.PureComponent {
|
||||
legacyImplementation={false}
|
||||
numColumns={1}
|
||||
onRefresh={() => alert('onRefresh: nothing to refresh :P')}
|
||||
refreshing={false}
|
||||
onViewableItemsChanged={this._onViewableItemsChanged}
|
||||
ref={this._captureRef}
|
||||
refreshing={false}
|
||||
shouldItemUpdate={this._shouldItemUpdate}
|
||||
/>
|
||||
</UIExplorerPage>
|
||||
|
||||
Reference in New Issue
Block a user