Steps to Add a Custom Splash Fragment
1. Create a Splash Fragment
Create a new fragment that extendsAbstractSplashFragment. This is where you’ll define your splash Fragment’s layout and any custom logic.
2. Create a Splash Factory
Create a factory class that implementsChoicelySplashFactory. This factory is responsible for providing an instance of your custom splash fragment.
3. Add the Factory in Your Application Class
Finally, in yourApplication class (e.g., YourApplication.java or YourApplication.kt), add a call to ChoicelySDK.factory().setSplashFactory() to use your custom splash Fragment.
Remember to create a layout file named
fragment_custom_splash.xml in your res/layout directory to define the visual elements of your splash Fragment, such as an image, text, or a animation view.