leecade / leecade/react-native-swiper

Warning: Failed prop type: The prop `children` is marked as required in `_default`, but its value is `undefined`.

Open
#1,367 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
10.5k
Forks
2.3k
PR merge metrics
No merged PRs in 30d

Description

android

  • react-native-swiper v 1.6.0?
  • react-native v 0.73.1

i am facing waring when apply swiper

<Swiper
automaticallyAdjustCotentInsets
showsButtons={false}
autoplay={true}
autoplayTimeout={3}
activeDotColor={COLORS.gray}
dotColor={COLORS.gray}
dotStyle={style.dotStyle}
style={[style.slide2, {...slideStyle}]}
activeDotStyle={[
style.dotStyle,
{
backgroundColor: COLORS.red,
},
]}>
{imageData?.map((x, i) => {
return (

<Image
key={i}
resizeMode={resizeMode}
containerStyle={[style.wrap, {...wrapStyle}]}
source={{uri: imageURL(x?.banner_image)}}
PlaceholderContent={
<Image
key={i}
source={require('../../assets/img/placeholder_rectangle.png')}
style={[style.wrap, {...wrapStyle}]}
/>
}
/>

);
})}

below are my code
they give warning related childern

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the reported Swiper JSX and inspect how react-native-swiper validates its children using the listed React Native and swiper versions. Reproduce the warning with the supplied imageData mapping, then determine whether the component or the usage causes the required children prop to be undefined.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react-native
Domain
mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.