Unable to use reanimated-bottom-sheet in React-Native

Viewed 1848

I install reanimated-bottom-sheet in my react native project but I faced with this error

TypeError: undefined is not an object (evaluating 'InnerNativeModule.installCoreFunctions') ERROR Invariant Violation: Module AppRegistry is not a registered callable module (calling runApplication). A frequent cause of the error is that t frequent cause of the error is that the application entry file path is incorrect. This can also happen when the JS bundle is corrupt or there is an early initialization error when loading React Native.

this is my code :

import BottomSheet from 'reanimated-bottom-sheet';

const renderContent = () => (
    <View
        style={{
            backgroundColor: 'white',
            padding: 16,
            height: 450,
        }}
    >
        <Text>Swipe down to close</Text>
    </View>
);

const sheetRef = React.useRef(null);

return (
    <SafeAreaView>
        <View
            style={{
                flex: 1,
                backgroundColor: 'papayawhip',
                alignItems: 'center',
                justifyContent: 'center',
            }}
        >
            <Button
                title="Open Bottom Sheet"
                onPress={() => sheetRef.current.snapTo(1)}
            />
        </View>
        <BottomSheet
            ref={sheetRef}
            snapPoints={[450, 300, 0]}
            borderRadius={10}
            renderContent={renderContent}
        />
    </SafeAreaView>
);

Please advise what I am doing wrong.

Thanks in advance

1 Answers
Related