When I open the release apk which is made using kitten UI, the app shows a black screen at startup for at least 2 to 4 seconds
<ApplicationProvider {...eva} theme={{...eva.light, ...theme}}>
UI Kitten and Eva version
Package Version
"@ui-kitten/components": "^5.3.1",
"@ui-kitten/eva-icons": "^5.3.1",
"@eva-design/eva": "^2.2.0",
My Metro-config code
const {getDefaultConfig, mergeConfig} = require('@react-native/metro-config');
const MetroConfig = require('@ui-kitten/metro-config');
const evaConfig = {
evaPackage: '@eva-design/eva',
// Optional, but may be useful when using mapping customization feature.
customMappingPath: './mapping.json',
};
// Make sure to handle any errors that might occur during configuration
module.exports = async () => {
try {
const defaultConfig = await getDefaultConfig(__dirname);
// Use mergeConfig from @react-native/metro-config to merge configurations
const mergedConfig = mergeConfig(defaultConfig, {
// Add your custom configuration options here if needed
});
// Create the final configuration using @ui-kitten/metro-config
const finalConfig = MetroConfig.create(evaConfig, mergedConfig);
return finalConfig;
} catch (error) {
// Handle errors appropriately, e.g., log them or throw
console.error('Error configuring Metro bundler:', error);
throw error;
}
};