Avatar
The #if/#endif compiler conditionals surrounding PreviewProvider types have been removed from SwiftUI templates. PreviewProviders aren’t properly removed from built products when archived. (51539802) https://developer.apple.com/documentation/xcode-release-notes/xcode-11-release-notes#3384944
PreviewProviderに#ifが必要ないのって、あくまでDead Code Elimination最適化で消えるからであって言語の機能じゃないですよね? 僕はこれが気持ち悪くていつも#ifでリリース時に入らないようにしているんですが、皆さんどうしてますか?
(edited)