From 6a4fa1cfd91e54c911282c2ebbb2c350b1e7558c Mon Sep 17 00:00:00 2001 From: redstrate <54911369+redstrate@users.noreply.github.com> Date: Wed, 3 Jun 2020 21:33:48 -0400 Subject: [PATCH] Add navigation view --- MobileFort/MobileFort/ContentView.swift | 14 +++++++++----- MobileFort/MobileFort/SceneDelegate.swift | 2 +- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/MobileFort/MobileFort/ContentView.swift b/MobileFort/MobileFort/ContentView.swift index dfe33f9..4ba668f 100644 --- a/MobileFort/MobileFort/ContentView.swift +++ b/MobileFort/MobileFort/ContentView.swift @@ -1,13 +1,17 @@ import SwiftUI -struct ContentView: View { +struct ProfileView: View { var body: some View { - Text("Hello, World!") + Text("Hello, world!") } } -struct ContentView_Previews: PreviewProvider { - static var previews: some View { - ContentView() +struct MainView: View { + var body: some View { + NavigationView { + NavigationLink(destination: ProfileView()) { + Text("Show Feed") + } + } } } diff --git a/MobileFort/MobileFort/SceneDelegate.swift b/MobileFort/MobileFort/SceneDelegate.swift index 9e9ee9b..95f64c6 100644 --- a/MobileFort/MobileFort/SceneDelegate.swift +++ b/MobileFort/MobileFort/SceneDelegate.swift @@ -6,7 +6,7 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate { func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) { - let contentView = ContentView() + let contentView = MainView() if let windowScene = scene as? UIWindowScene { let window = UIWindow(windowScene: windowScene)