iOS SwiftUI builder

I am thinking about making an app that lets you experiment and prototype SwiftUI views in iOS. I was wondering if allowing user to have limited state/storage and functionally, for example a toggle connected to an if else in a view, would be allowed or disallowed by guideline 2.5.2. The app would probably use JavaScript in the background to simulate swift execution, but may use something else.

iOS SwiftUI builder
 
 
Q