Skip to content

Instantly share code, notes, and snippets.

@ufo22940268
Created August 27, 2020 02:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ufo22940268/220cd201bff4b7e998d440d101cca3f4 to your computer and use it in GitHub Desktop.
Save ufo22940268/220cd201bff4b7e998d440d101cca3f4 to your computer and use it in GitHub Desktop.
struct ContentView: View {
@ObservedObject var entity: MyEntity
var body: some View {
NavigationView {
VStack {
Text("asdfasdf \(entity.name!)")
Button("btn") {
self.entity.name = "kkkkkkkk"
}
NavigationLink(destination: ContentView(entity: entity)) {
Text("jump")
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment