Hello,
We all well know about the SplitviewController. Apple highly recommends it to use as a root view controller whenever we use it.
But for me, I have to use SplitViewController in a Framework where my SDK user apps may or may not support the Splitview. So, for common my SDK needs to support splitview even the Apps doesn't.
So here comes the ???
how to present SplitViewController rather than having it as RootViewController
Presenting modely is an option but still not fully aware of its pros and difficulties
What will be the correct way, does anyone tried it?
Even if you don't recommend this kindly share your thoughts about its disadvantages, thanks in advance.
Have a nice day 🤗
Apple say:
"...the split view controller is typically the root view controller of your app’s window."
typically... so it doesn't have to be.
Alternatively, can't you just set your rootViewController in code (based on some condition, where the app supports SplitViewController)?
if supportsSplitViewController {
appDelegate?.window??.rootViewController = splitViewController
} else {
// something else...
}