Skip to content
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

[Reanimated] Property text was whitelisted both as UI and native prop. Please remove it from one of the lists. #518

Open
enchorb opened this issue Dec 8, 2023 · 2 comments

Comments

@enchorb
Copy link

enchorb commented Dec 8, 2023

[Reanimated] Property text was whitelisted both as UI and native prop. Please remove it from one of the lists.

After upgrading to reanimated 3.6.0 I am getting the following error thrown from the ReText.tsx file in this library

@enchorb
Copy link
Author

enchorb commented Dec 8, 2023

This patch fixed the error for me

diff --git a/lib/module/ReText.js b/lib/module/ReText.js
index 255a9eb667228850439c61a27abbe290a2b6fae0..aa5a6b676d369ed4914ec992976d11116342fb26 100644
--- a/lib/module/ReText.js
+++ b/lib/module/ReText.js
@@ -1,2 +1,2 @@
-import _extends from"@babel/runtime/helpers/extends";import _objectWithoutProperties from"@babel/runtime/helpers/objectWithoutProperties";var _jsxFileName="/home/circleci/repo/src/ReText.tsx";var _excluded=["style","text"];import React from"react";import{StyleSheet,TextInput}from"react-native";import Animated,{useAnimatedProps}from"react-native-reanimated";var styles=StyleSheet.create({baseStyle:{color:"black"}});Animated.addWhitelistedNativeProps({text:true});var AnimatedTextInput=Animated.createAnimatedComponent(TextInput);var ReText=function ReText(props){var style=props.style,text=props.text,rest=_objectWithoutProperties(props,_excluded);var animatedProps=useAnimatedProps(function(){return{text:text.value};});return React.createElement(AnimatedTextInput,_extends({underlineColorAndroid:"transparent",editable:false,value:text.value,style:[styles.baseStyle,style||undefined]},rest,{animatedProps:animatedProps,__source:{fileName:_jsxFileName,lineNumber:30,columnNumber:5}}));};export default ReText;
+import _extends from"@babel/runtime/helpers/extends";import _objectWithoutProperties from"@babel/runtime/helpers/objectWithoutProperties";var _jsxFileName="/home/circleci/repo/src/ReText.tsx";var _excluded=["style","text"];import React from"react";import{StyleSheet,TextInput}from"react-native";import Animated,{useAnimatedProps}from"react-native-reanimated";var styles=StyleSheet.create({baseStyle:{color:"black"}});var AnimatedTextInput=Animated.createAnimatedComponent(TextInput);var ReText=function ReText(props){var style=props.style,text=props.text,rest=_objectWithoutProperties(props,_excluded);var animatedProps=useAnimatedProps(function(){return{text:text.value};});return React.createElement(AnimatedTextInput,_extends({underlineColorAndroid:"transparent",editable:false,value:text.value,style:[styles.baseStyle,style||undefined]},rest,{animatedProps:animatedProps,__source:{fileName:_jsxFileName,lineNumber:30,columnNumber:5}}));};export default ReText;
 //# sourceMappingURL=ReText.js.map
\ No newline at end of file

@enchorb
Copy link
Author

enchorb commented May 10, 2024

@wcandillon any ETA on an actual fix for this, I can make a PR if needed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant