SwiftUI Preview timeout for large project

Viewed 3324

I've been trying to preview SwiftUI files in my large iOS project and cannot get past this error TimeoutError: Timed out waiting for a thunk to build after 30.0 seconds.

What's interesting/confusing is that a newly created SwiftUI file with the default "Hello World" Text does successfully load the preview in the same project, however more complex SwiftUI files show the time out error even when I change the preview struct to display a Text("Hello World") view.

Has anyone else experienced this or could point in what direction I can dig to fix this timeout issue?

1 Answers

In case it helps someone else... I ended being able to load the previews by temporarily setting the project to iOS 13 development target (normally it's iOS 12). Thankfully we'll be dropping iOS 12 soon so this won't be an issue after that.

Related