struct ContentView: View { @State var isPresentedSubView = false var body: some View { VStack { Button(action: { self.isPresentedSubView.toggle() }) { Text("モーダル画面を表示") } .sheet(isPresented: $isPresentedSubView) { SubView() } } } } struct SubView: View { var body: some View { VStack { Text("SubView") } } }