SwiftUI Canvas won't build

后端 未结 2 507
轻奢々
轻奢々 2021-01-28 13:36

I have some SwiftUI code and it seems to work great when I build to a real iOS device or to an iOS simulator.

However in the SwiftUI canvas the preview says Failed

2条回答
  •  故里飘歌
    2021-01-28 13:55

    So I had this same issue except it couldn't find my own module... For me the problem was because I have custom build configurations and it didn't like the custom module name. The solution was to rename the module to the same as debug and release in Build Settings > Product Module Name

    I hope this helps someone

提交回复
热议问题