2

I am trying to optimize my SwiftUI preview build times.

In my project I have two schemes, one for dev and one for prod, with different configurations. When I kick off a SwiftUI preview build, both schemes are built in sequence. This almost doubles my build time.

Does anyone have an explanation as to why that happens?

Steps to reproduce:

I'm working with XClogparser to to visualize my build times.

When I start a regular, non-preview build, only the selected scheme is built, as expected.

When I kick off a SwiftUI preview build, I can see in the build log that after building my dev my production scheme is built as well. The buildscripts and compilations of both schemes are run, in series.

I'm using Xcode 14.1

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.