-
Notifications
You must be signed in to change notification settings - Fork 182
Open
Description
Hey @jfilter 👋 , I'm using this component in a "react-native": "^0.72.3", app but run into a runtime error on render. Seems there is some bug with the FlatList used internally in Onboarding component (react-native-onboarding-swiper) - "ERROR TypeError: Cannot read property 'getItem' of undefined".
Any ideas what's wrong here? Looking at my usage below it seems to be following the same config as your simple-example . Also the image resource is in the same folder specified in the require path.
Component usage:
import React from 'react';
import {View, Text, TouchableOpacity, Image} from 'react-native';
import Onboarding from 'react-native-onboarding-swiper';
return (
<Onboarding
pages={[
{
backgroundColor: '#fff',
image: <Image source={require('../images/diagram-1.png')} />,
title: 'Welcome to Simple Offset Pro',
subtitle:
'Effortlessly calculate square offsets and bend cable tray or HVAC ducting sheet metal with Simple Offset',
},
]}
/>
);
};
export default CustomOnboardingComponent;
Error log while debugging the app locally:
ERROR TypeError: Cannot read property 'getItem' of undefined
This error is located at:
in FlatList (created by Onboarding)
in RCTView (created by View)
in View
in Unknown (created by Onboarding)
in Onboarding (created by OnboardingComponent)
in OnboardingComponent (created by SceneView)
in StaticContainer
in EnsureSingleNavigator (created by SceneView)
in SceneView (created by SceneView)
in RCTView (created by View)
in View (created by DebugContainer)
in DebugContainer (created by MaybeNestedStack)
Metadata
Metadata
Assignees
Labels
No labels