Skip to content

VirtualList debug mode error #24053

@HaloWang

Description

@HaloWang

🐛 Bug Report

Get errors when setting FlatList - debug={true}
Simulator Screen Shot - iPhone 8 - 2019-03-20 at 14 24 55

To Reproduce

cd Destop && react-native init VirtualListDebugDemo && cd VirtualListDebugDemo && react-native run-ios

Expected Behavior

debug mode work fine

Code Example

Edit the App.js:

import React, { Component } from 'react'
import { Text, FlatList } from 'react-native'

export default class App extends Component {
  render() {
    return (
      <FlatList
        //  ❌ Un-commit this line to see error
        // debug={true}
        data={[1, 2, 3, 4, 5, 6]}
        renderItem={_ => {
          return <Text>123</Text>
        }}
        keyExtractor={item => item.toString()}
      />
    )
  }
}

Environment

info 
  React Native Environment Info:
    System:
      OS: macOS 10.14.3
      CPU: (8) x64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz
      Memory: 817.49 MB / 16.00 GB
      Shell: 5.3 - /bin/zsh
    Binaries:
      Node: 11.3.0 - /usr/local/bin/node
      Yarn: 1.13.0 - /usr/local/bin/yarn
      npm: 6.9.0 - /usr/local/bin/npm
      Watchman: 4.9.0 - /usr/local/bin/watchman
    SDKs:
      iOS SDK:
        Platforms: iOS 12.1, macOS 10.14, tvOS 12.1, watchOS 5.1
      Android SDK:
        API Levels: 19, 23, 25, 26, 27, 28
        Build Tools: 23.0.1, 23.0.3, 25.0.2, 26.0.2, 27.0.3, 28.0.3
        System Images: android-23 | Intel x86 Atom, android-23 | Intel x86 Atom_64, android-23 | Google APIs ARM EABI v7a, android-23 | Google APIs Intel x86 Atom, android-23 | Google APIs Intel x86 Atom_64
    IDEs:
      Android Studio: 3.3 AI-182.5107.16.33.5264788
      Xcode: 10.1/10B61 - /usr/bin/xcodebuild
    npmPackages:
      react: 16.8.3 => 16.8.3 
      react-native: 0.59.1 => 0.59.1 
    npmGlobalPackages:
      react-native-cli: 2.0.1
      react-native-create-library: 3.1.2
      react-native-git-upgrade: 0.2.7

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions