Learn that Modal display is controlled by the visible prop.
import React from 'react'; import { Modal, Text } from 'react-native'; export default function Popup({ open }) { return ( <Modal show={open}> <Text>Hello</Text> </Modal> ); }
What is the bug in this code?