Need to check if "style" prop is an array
See original GitHub issueIssue Description
this.props = { ...this.props, style: [customProps.style, this.props.style] };
when this.props.style
is an array, this will not work properly. In my case, it ignores customProps.style
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:5
Top Results From Across the Web
Array.isArray() - JavaScript - MDN Web Docs
The Array.isArray() static method determines whether the passed value is an Array.
Read more >How to check some prop in object equal some in other arrays?
Now i have a checkbox the value of it is "true/false" i want to compare if the response comes from API it's in...
Read more >Lists and Keys - React
Lists and Keys ... First, let's review how you transform lists in JavaScript. Given the code below, we use the map() function to...
Read more >Class and Style Bindings | Vue.js
When you use a CSS property that requires a vendor prefix in :style , Vue will automatically add the appropriate prefix. Vue does...
Read more >Docs • Svelte
If you don't need a full-fledged app framework and instead want to build a simple ... If you'd like to track changes to...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@mahesh1996 I got it on some elements too, but have deleted the code, will let you know if I happen to reproduce it.
@thomasttvo Tested on react-native 0.51. It works fine as
Text
can accept style object or recursive array of style objects.