This simple code that I want to observe the body
calculation doesn't work:
struct ContentView: View {
@State var isOn = false
var body: some View {
print("MainView body")
return Toggle("Toggle", isOn: $isOn)
}
}
When I toggle the Toggle
I'm getting errors:
On iOS:
[5502:364282] invalid mode 'kCFRunLoopCommonModes' provided to CFRunLoopRunSpecific - break on _CFRunLoopError_RunCalledWithInvalidMode to debug. This message will only appear once per execution.
On macOS:
[5522:365624] Metal API Validation Enabled
[5522:365624] Unable to locate MetalPluginName property or is of the wrong type
[5522:365624] +[MTLIOAccelDevice registerDevices]: Zero Metal services found
What am I doing wrong?