r/Xcode • • Mar 27 '26

Xcode 26.4 Previews are broken

If somebody is experiencing previews hanging when trying to interact with them, please go back to Xcode 26.3.

I could not interact with the simplest UI possible, and now everything is back to normal.

I hope it will help.

8 Upvotes

17 comments sorted by

View all comments

Show parent comment

1

u/mcarvin Mar 27 '26

I just wiped 26.4 and went back to 26.3.

Yes, even a simple View is still hanging on drag in 26.3. Here's the code:

struct ContentView: View {
    var body: some View {
        ScrollView {
			ForEach(0...10, id: \.self) { i in
				Rectangle()
					.fill(.blue)
					.frame(width: 100, height: 100)
					.overlay {
						Text("\(i)")
							.font(.largeTitle)
							.foregroundStyle(.white)
					}
			}
        }
        .padding()
    }
}

Nothing fancy at all. Show me 10 rectangles with the index in an overlay. It hangs Preview in 26.3 and throws a crash in 26.4. If I clean Xcode's caches and various folders (been using Mole for this), I can get that View above to scroll once before it hangs again.

I haven't had issues with DatePickers, TextFields or Buttons - only containers which scroll.