Capacitor and SplashScreen
-
I am having difficulties to disable splash screen in capacitor.
I added to App.Vue
import { Plugins } from '@capacitor/core' const { SplashScreen } = Plugins SplashScreen.hide()
that didn’t do a thing. I also tried to set in quasar config and/or capacitor.config.json but no joy.
"plugins": { "SplashScreen": { "launchShowDuration": 0, "launchAutoHide": true, "backgroundColor": "#ffffffff", "androidSplashResourceName": "splash", "androidScaleType": "CENTER_CROP", "androidSpinnerStyle": "large", "iosSpinnerStyle": "small", "spinnerColor": "#999999", "showSpinner": true } }
I have my own component with splash screen, is there any way to disable capacitor splash screen ?
-
Hi. I’m having problems also with the splash screen, but I found the splash screen generated by Quasar may not be the same splash screen controlled by Capacitor Plugin, because adding settings to capacitor.config.json what I get is two splash screens.
I’ll post here if I found something else.
-
@ramsesmoreno
file: capacitor.config.json
“plugins”: {
“SplashScreen”: {
“launchAutoHide”: false,
“backgroundColor”: “#ffffffff”,
“androidSplashResourceName”: “splash”,
“androidScaleType”: “CENTER_CROP”,
“androidSpinnerStyle”: “large”,
“iosSpinnerStyle”: “small”,
“spinnerColor”: “#999999”,
“showSpinner”: true
}
}
file: App.vue
import { Plugins } from ‘@capacitor/core’;
const { SplashScreen } = Plugins;
export default {
name: ‘App’,
created () {
Capacitor.isNative ? SplashScreen.hide() : null
}, -
Thank you @jadedRepublic for your time. The Capacitor Splash Screen is showing, correct proportion, spinner… bit It still shows a previous splash screen without correct proportions. I can’t figure out if it is something Icon Genie is controlling.
-
@ramsesmoreno Is It showing 2 different splash screens by any chance? I vague remember getting the same error, I just tried a fresh install of Quasar and It work as expected without changing anything