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.

Warning: Received `false` for a non-boolean attribute `uppercase`

See original GitHub issue

Hi. Getting this warning in a web browser console

bundle.js:144396 Warning: Received false for a non-boolean attribute uppercase.

If you want to write it to the DOM, pass a string instead: uppercase=“false” or uppercase={value.toString()}.

If you used to conditionally omit it with uppercase={condition && value}, pass uppercase={condition ? value : undefined} instead. in div (created by Text) in Text (at Text.js:26) in Text (at connectStyle.js:392) in Styled(Text) (at SettingsScreen.js:19) in div (created by View) in View (at Left.js:10) in Left (at connectStyle.js:392) in Styled(Left) (at SettingsScreen.js:18) in div (created by View) in View (at ListItem.js:39) in div (created by View) in View (created by TouchableHighlight) in TouchableHighlight (at ListItem.js:31) in ListItem (at connectStyle.js:392) in Styled(ListItem) (at SettingsScreen.js:17) in div (created by View) in View (at List.js:25) in List (at connectStyle.js:392) in Styled(List) (at SettingsScreen.js:15) in div (created by View) in View (created by ScrollView) in div (created by View) in View (created by ScrollViewBase) in ScrollViewBase (created by ScrollView) in ScrollView (at KeyboardAwareHOC.js:517) in KeyboardAwareScrollView (at Content.js:66) in Content (at connectStyle.js:392) in Styled(Content) (at SettingsScreen.js:14) in div (created by View) in View (at Container.js:12) in Container (at connectStyle.js:392) in Styled(Container) (at SettingsScreen.js:13) in SettingsScreen (at SceneView.js:9) in SceneView (at StackViewLayout.tsx:898) in div (created by View) in View (at StackViewLayout.tsx:897) in div (created by View) in View (at StackViewLayout.tsx:896) in div (created by View) in View (created by AnimatedComponent) in AnimatedComponent (at StackViewCard.tsx:106) in div (created by View) in View (created by AnimatedComponent) in AnimatedComponent (at screens.web.js:105) in Screen (at StackViewCard.tsx:93) in Card (at createPointerEventsContainer.tsx:95) in Container (at StackViewLayout.tsx:984) in div (created by View) in View (at StackViewLayout.tsx:393) in div (created by View) in View (created by AnimatedComponent) in AnimatedComponent (at StackViewLayout.tsx:383) in UnimplementedGestureHandler (at createHandler.web.js:201) in PanGestureHandler (at StackViewLayout.tsx:376) in StackViewLayout (at withOrientation.js:30) in withOrientation (at StackView.tsx:104) in div (created by View) in View (at Transitioner.tsx:267) in Transitioner (at StackView.tsx:41) in StackView (at createNavigator.js:80) in Navigator (at SceneView.js:9) in SceneView (at createTabNavigator.tsx:67) in div (created by View) in View (created by AnimatedComponent) in AnimatedComponent (at screens.web.js:105) in Screen (at ResourceSavingScene.tsx:20) in ResourceSavingScene (at createBottomTabNavigator.tsx:157) in div (created by View) in View (at createBottomTabNavigator.tsx:147) in div (created by View) in View (at createBottomTabNavigator.tsx:146) in TabNavigationView (at createTabNavigator.tsx:228) in NavigationView (at createNavigator.js:80) in Navigator (at SceneView.js:9) in SceneView (at SwitchView.js:12) in SwitchView (at createNavigator.js:80) in Navigator (created by WebApp) in WebApp (at App.js:27) in div (created by View) in View (at App.js:25) in App (at withExpoRoot.web.js:8) in RootErrorBoundary (at withExpoRoot.web.js:7) in ExpoRootComponent (at registerRootComponent.web.js:6) in RootComponent in div (created by View) in View (created by AppContainer) in div (created by View) in View (created by AppContainer) in AppContainer

Note: Getting this warning only in web

packages used: Node js v10.16.0 “@expo/samples”: “~3.0.3”, “@expo/vector-icons”: “^10.0.5”, “@react-navigation/web”: “^1.0.0-alpha.9”, “expo”: “^35.0.0”, “expo-asset”: “^7.0.0”, “expo-constants”: “7.0.0”, “expo-font”: “~7.0.0”, “expo-web-browser”: “7.0.1”, “jwt-decode”: “^2.2.0”, “native-base”: “^2.13.8”, “react”: “16.9.0”, “react-dom”: “16.8.3”, “react-native”: “0.59.8”

the full list in the package.json in the repo

Expected behaviour

no such kind of warnings

Actual behaviour

there is a Warning: Received false for a non-boolean attribute uppercase in the web browser console

Steps to reproduce

Repo with the code that reproduces this warning https://github.com/arsamigullin/native-base-issue

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:8
  • Comments:14 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
jmatsushitacommented, Dec 3, 2019

This message comes from the defaultProps here https://github.com/GeekyAnts/NativeBase/blob/9c470822dc4912c3780cf14426cd3b6a56ef01f4/src/basic/Text.js#L44

Removing this statement gets rid of the warning on react-native-web with no apparent problems caused on the react-native side of things.

2reactions
ajitdas123commented, May 9, 2020

@hanykumar This issue arises when we are using native base with react-native-web.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Warning: Received `false` for a non-boolean attribute. How do ...
This error with styled-components appears to be due to styled() attempting to apply a boolean ...
Read more >
How to fix the 'Received "true" for a non-boolean attribute' error
The trick is to use the unary plus operator to convert boolean to number. before your booleans values. According to MDN unary operator...
Read more >
How to Fix ' Received false for non-boolean attribute' Errors
The "Warning: Received false for a non-boolean attribute className." warning happens in React when you try to conditionally set a attribute, ...
Read more >
Warning: Received true for non-boolean attribute gray . #1198
How can I resolve this warning? Warning: Received `true` for non-boolean attribute `gray`. If this is expected, cast the value to a string....
Read more >
Warning: Received true for a non boolean attribute jsx
If you want to write it to the DOM, pass a string instead: uppercase="false" or uppercase={value. toString()}.
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