I'm trying to apply some navigationBarItems to my View and I've gotten this error - Type '() -> Text' cannot conform to 'View'; only struct/enum/class types can conform to protocols
I've been able to dumb the code down to this. Anyone know what could be causing it?
struct NewEntry: View {
var body: some View {
NavigationView {
VStack {
Text("Hello World")
}
.navigationBarItems(trailing: {
Text("Hello World")
})
}
}
}