traitOverrides.horizontalSizeClass = .compact
Works but not if you want to see more than 4 tabs at the bottom.
traitOverrides.horizontalSizeClass = .unspecified
Works if you want to see more than 4 tabs at the bottom.
Post
Replies
Boosts
Views
Activity
traitOverrides.horizontalSizeClass = .compact
If you use .compact and your app has more than 4 tabs the 5th tab will have a More... option, which is not what you want. To restore the same functionality you have to use the following
traitOverrides.horizontalSizeClass = .unspecified
traitOverrides.horizontalSizeClass = UIUserInterfaceSizeClassUnspecified;