React-native: [React-native 0.56] [Toggle Inspector] renderer.getInspectorDataForViewTag is not a function

Created on 12 Sep 2018  路  8Comments  路  Source: facebook/react-native

Environment

React Native Environment Info:
    System:
      OS: macOS Sierra 10.12.6
      CPU: x64 Intel(R) Core(TM) i7-4771 CPU @ 3.50GHz
      Memory: 613.02 MB / 32.00 GB
      Shell: 3.2.57 - /bin/bash
    Binaries:
      Node: 9.1.0 - ~/.nvm/versions/node/v9.1.0/bin/node
      npm: 5.5.1 - ~/.nvm/versions/node/v9.1.0/bin/npm
      Watchman: 4.9.0 - /usr/local/bin/watchman
    SDKs:
      iOS SDK:
        Platforms: iOS 11.2, macOS 10.13, tvOS 11.2, watchOS 4.2
      Android SDK:
        Build Tools: 23.0.1, 23.0.2, 23.0.3, 26.0.0, 26.0.1, 26.0.2, 26.0.3, 27.0.0, 27.0.1, 27.0.2, 27.0.3
        API Levels: 23, 25, 26, 27
    IDEs:
      Android Studio: 3.1 AI-173.4697961
      Xcode: 9.2/9C40b - /usr/bin/xcodebuild
    npmPackages:
      react: ^16.4.1 => 16.4.2
      react-native: ^0.56.0 => 0.56.0
    npmGlobalPackages:
      create-react-native-app: 1.0.0
      react-native-git-upgrade: 0.2.7

Description

After upgrate RN to 0.56, I'm try Toggle Inspector but that below error occur when I click anywhere in screen
simulator screen shot - iphone 7 - 2018-09-12 at 17 35 21

Ran Commands Locked

Most helpful comment

Can confirm that upgrading to 0.57.0 of just the react-native package.json dependency did not fix the issue.

All 8 comments

It looks like you are using an older version of React Native. Please update to the latest release, v0.57 and verify if the issue still exists.

The ":rewind:Old Version" label will be removed automatically once you edit your original post with the results of running react-native info on a project using the latest release.

Can confirm that upgrading to 0.57.0 of just the react-native package.json dependency did not fix the issue.

I am closing this issue because it does not appear to have been verified on the latest release, and there has been no followup in a while.

If you found this thread after encountering the same issue in the latest release, please feel free to create a new issue with up-to-date information by clicking here.

Found out the solution to this problem for us. We had a library, react-metrics, from which we imported a single named export. Turns out the lib goes ahead and enables screen tracking (taps, gestures) metrics for you even if you don't import those other functions. So we did a deep import e.g. import blah from react-metrics/some/sub/folder and this resolved the issue.

Found out the solution to this problem for us. We had a library, react-metrics, from which we imported a single named export. Turns out the lib goes ahead and enables screen tracking (taps, gestures) metrics for you even if you don't import those other functions. So we did a deep import e.g. import blah from react-metrics/some/sub/folder and this resolved the issue.

could you code here ?

@CxxyLucifer
My solution is here: https://github.com/facebook/react-native/pull/21237/files

3Q, nice

I'll land the attached PR to fix this issue.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

oney picture oney  路  3Comments

jlongster picture jlongster  路  3Comments

grabbou picture grabbou  路  3Comments

TrakBit picture TrakBit  路  3Comments

anchetaWern picture anchetaWern  路  3Comments