Why do I get this warning when I try to create my custom splash screen?

Can I get rid of this without using @SuppressLint("CustomSplashScreen")
>Solution :
Probably because with android-12 there is a new API to build Splash Screen . You can go through the migration guide if you want to implement new API . If you want keep older one you have to use @SupressLint because you are targeting android-12.