question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'.

See original GitHub issue

Description

Recentrly update React ANtive Version to "react-native": "0.68.0", and have this issue

WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN EdgeInsetsPropType will be removed from React Native. Migrate to EdgeInsetsPropType exported from 'deprecated-react-native-prop-types'. WARN EdgeInsetsPropType will be removed from React Native. Migrate to EdgeInsetsPropType exported from 'deprecated-react-native-prop-types'. WARN PointPropType will be removed from React Native. Migrate to PointPropType exported from 'deprecated-react-native-prop-types'. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'.

Version

0.68.0

Output of npx react-native info

System: OS: macOS 12.3.1 CPU: (8) x64 Apple M1 Memory: 30.51 MB / 8.00 GB Shell: 5.8 - /bin/zsh Binaries: Node: 17.8.0 - /usr/local/bin/node Yarn: 1.22.18 - /usr/local/bin/yarn npm: 8.5.5 - /usr/local/bin/npm Watchman: 2022.03.14.00 - /usr/local/bin/watchman Managers: CocoaPods: 1.11.3 - /usr/local/bin/pod SDKs: iOS SDK: Platforms: DriverKit 21.4, iOS 15.4, macOS 12.3, tvOS 15.4, watchOS 8.5 Android SDK: API Levels: 30, 32 Build Tools: 30.0.2, 32.0.0, 32.1.0 System Images: android-30 | Intel x86 Atom_64, android-32 | Google APIs ARM 64 v8a Android NDK: Not Found IDEs: Android Studio: 2021.1 AI-211.7628.21.2111.8193401 Xcode: 13.3/13E113 - /usr/bin/xcodebuild Languages: Java: 11.0.11 - /usr/bin/javac npmPackages: @react-native-community/cli: Not Found react: 17.0.2 => 17.0.2 react-native: 0.68.0 => 0.68.0 react-native-macos: Not Found npmGlobalPackages: react-native: Not Found

Steps to reproduce

npx react-native start

Snack, code example, screenshot, or link to a repository

WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN EdgeInsetsPropType will be removed from React Native. Migrate to EdgeInsetsPropType exported from ‘deprecated-react-native-prop-types’. WARN EdgeInsetsPropType will be removed from React Native. Migrate to EdgeInsetsPropType exported from ‘deprecated-react-native-prop-types’. WARN PointPropType will be removed from React Native. Migrate to PointPropType exported from ‘deprecated-react-native-prop-types’. WARN ColorPropType will be removed from React Native. Migrate to ColorPropType exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’. WARN ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from ‘deprecated-react-native-prop-types’.

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:64
  • Comments:139 (8 by maintainers)

github_iconTop GitHub Comments

229reactions
nibblesnbitscommented, Apr 8, 2022

So now we just ignore deprecation messages now instead of learning what we actually need to fix? Sounds like a great practice…

87reactions
Gnativecommented, Aug 11, 2022

Ignore certain logs with LogBox.ignoreLogs([])

LogBox.ignoreLogs(): This function replaces YellowBox.ignoreLogs([]) as a way to silence any logs that match the given strings or regexes. LogBox.ignoreAllLogs(): This function replaces console.disableYellowBox as a way to turn off error or warning notifications. Note: this only disables notifications, uncaught errors will still open a full screen LogBox.

https://reactnative.dev/blog/2020/07/06/version-0.63#logbox

import {LogBox} from "react-native";

LogBox.ignoreLogs([
"ViewPropTypes will be removed",
"ColorPropType will be removed",
])

or you could use, below, to silence all PropType warnings

import {LogBox} from "react-native";

LogBox.ignoreLogs([
"exported from 'deprecated-react-native-prop-types'.",
])
Read more comments on GitHub >

github_iconTop Results From Across the Web

ViewPropTypes will be removed from React ... - Stack Overflow
ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types · Solution:.
Read more >
React Native Tutorial - ERROR Invariant Violation - YouTube
Migrate to ViewPropTypes exported from ' deprecated-react-native-prop-types '. viewproptypes will be removed from react native viewproptypes ...
Read more >
viewproptypes has been removed from react native. migrate to ...
ViewPropTypes will be removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types.
Read more >
deprecated-react-native-prop-types - npm
Deprecated prop-types from React Native.. Latest version: 4.0.0, last published: 11 days ago. Start using deprecated-react-native-prop-types ...
Read more >
viewproptypes will be removed from react ... - Code Grepper
viewproptypes will be removed from react native. migrate to viewproptypes exported from 'deprecated-react-native-prop-types'.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found