-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix ViewPropTypes #81
Comments
Definitely this fixes the issue |
Hey guys any plans to implement this fix? |
The patch fixes the problem only partially, there are more deprecated PropTypes in use. diff --git a/node_modules/react-native-snackbar-component/index.js b/node_modules/react-native-snackbar-component/index.js
index ae1e313..7cc710f 100644
--- a/node_modules/react-native-snackbar-component/index.js
+++ b/node_modules/react-native-snackbar-component/index.js
@@ -2,11 +2,10 @@ import React, { Component } from 'react';
import PropTypes from 'prop-types';
import {
StyleSheet,
- Text,
Animated,
Easing,
- ViewPropTypes,
} from 'react-native';
+import { ViewPropTypes, TextPropTypes } from 'deprecated-react-native-prop-types';
import { Touchable } from './src';
/* Values are from https://material.io/guidelines/motion/duration-easing.html#duration-easing-dynamic-durations */
@@ -192,8 +191,8 @@ SnackbarComponent.propTypes = {
// eslint-disable-next-line react/no-unused-prop-types
autoHidingTime: PropTypes.number, // How long (in milliseconds) the snack bar will be hidden.
containerStyle: ViewPropTypes.style,
- messageStyle: Text.propTypes.style,
- actionStyle: Text.propTypes.style,
+ messageStyle: TextPropTypes.style,
+ actionStyle: TextPropTypes.style,
};
const styles = StyleSheet.create({
diff --git a/node_modules/react-native-snackbar-component/src/Touchable.js b/node_modules/react-native-snackbar-component/src/Touchable.js
index 0b08723..f5a6bbc 100644
--- a/node_modules/react-native-snackbar-component/src/Touchable.js
+++ b/node_modules/react-native-snackbar-component/src/Touchable.js
@@ -4,8 +4,8 @@ import {
View,
TouchableOpacity,
TouchableNativeFeedback,
- ViewPropTypes,
} from 'react-native';
+import { ViewPropTypes } from 'deprecated-react-native-prop-types';
import {
IS_ANDROID,
IS_LT_LOLLIPOP,
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi! 👋
Firstly, thanks for your work on this project! 🙂
Today I used patch-package to patch
react-native-snackbar-component@1.1.12
for the project I'm working on.Here is the diff that solved my problem:
This issue body was partially generated by patch-package.
The text was updated successfully, but these errors were encountered: