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.

Checkbox component - Warning: Failed prop type because of missing icon

See original GitHub issue

When using the Checkbox component, a warning: Failed prop type: invalid prop type name of value 'ios-checkmark-outline' is thrown with the latest version of @oblador/react-native-vector-icons.

Looks like the icon in question was renamed to ios-checkmark-circle: https://oblador.github.io/react-native-vector-icons/

When using CRNA (with Expo), the current version of @oblador/react-native-vector-icons (as expo/vector-icons) is automatically used, so I had to change the Native Base code for Checkbox manually for now.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

6reactions
cseeluscommented, Nov 8, 2018

@juanorellana13 Go to your projects node_modules folder and find the native-base folder. In there, you need to change ios-checkmark-outline to ios-checkmark in the following files:

  1. src/basic/icon/NBIcons.json:678
  2. dist/src/basic/icon/NBIcons.json:678
  3. src/basic/Checkbox.js:48
  4. dist/src/basic/Checkbox.js:1
  5. dist/src/basic/Checkbox.js.map:1

Thats what I did and it works in iOS Simulator as well as in the iOS app I built and tested via Apple Testflight.

Its easiest if you open the native-base folder with the editor of your choice and search for ios-checkmark-outline in that folder. That way all relevant files should turn up.

3reactions
Cookizzacommented, Nov 13, 2018

I have updated to 2.8.1 and still this issue persists.

The only difference i have is I’m using the expo icon wrapper @expo/vectoricons 8.0.0

Read more comments on GitHub >

github_iconTop Results From Across the Web

React How to fix Failed prop type - Invalid prop of type string ...
Try console.log of "errors" in the component where Login component is rendered to see what value is getting set.
Read more >
Invalid prop `checked` of type `array` supplied to `ForwardRef ...
Checkboxes and radios are failing with: warning: Failed prop type: Invalid prop checked of type array supplied to ForwardRef(Checkbox) ...
Read more >
Building a custom checkbox in React - LogRocket Blog
Let's start by creating a component called Checkbox that accepts a label text as a prop and renders a checkbox alongside the text:...
Read more >
invalid prop `rows` of type `object` supplied to `forwardref ...
Warning : Failed prop type: Invalid prop rows of type object supplied to ForwardRef(DataGrid), expected array.` Update after i remove the Object.fromEntries.
Read more >
Explore component properties - Figma Help Center
If you connect two components and consolidate them using boolean properties, the prototyping connections will be lost. For example, you have a boolean...
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