Ah yes, I now tried it in a project, and that works as expected. Before I tried it in a Playground, which did not work. So issue solved :)
Topic:
UI Frameworks
SubTopic:
SwiftUI
Tags: