Created
June 10, 2021 07:05
-
-
Save oliverepper/56161d402f169c2f92152c7041a387c2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct ContentView: View { | |
@State private var oben = false | |
var body: some View { | |
VStack { | |
if oben { | |
Text("HA").id(4) | |
Spacer() | |
} else { | |
Spacer() | |
Text("HA").id(4) | |
} | |
} | |
.animation(.linear(duration: 2.0)) | |
.font(.largeTitle) | |
.onTapGesture { | |
oben.toggle() | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment