Shivam Maggublog.shivammaggu.com·Feb 26, 2023Understanding SwiftUI - Why are Views in SwiftUI Struct and not Class?Why SwiftUI prefers Struct over Class? SwiftUI Views are structs instead of classes. This avoids having multiple inherited properties, keeps them lightweight and improves performance. SwiftUI Views are passed by value. This avoids retain cycles and...980 readsUnderstanding SwiftUISwift