Once, I found that the project had multiple targets. And the file wasn't a member of the currently selected target. But that only happened once. Other times, I found that repeatedly clicking the preview button (or repeatedly pressing Option-Cmd-P) fixed it. But most of the time, the preview is simply not appearing.
Xcode 12.0 and 12.2 series are rough for me, right now.
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags: