我正在做一个react native项目,我使用了react-native-bootsplash作为启动界面。问题是启动屏幕上的标志图像太小,因为启动屏幕标志的推荐尺寸是100。有没有办法调整图像的大小或使用由bootsplash生成的@5x图像??
我在react-native-bootsplash的文档(https://www.npmjs.com/package/react-native-bootsplash):
react-native generate-bootsplash <logoPath>
命令有几个参数:
Options:
--background-color <color> color used as launch screen background (in hexadecimal format) (default: "#fff")
--logo-width <width> logo width at @1x (in dp - we recommand approximately ~100) (default: 100)
--assets-path [path] path to your static assets directory (useful to require the logo file in JS)
--flavor <flavor> [android only] flavor build variant (outputs in an android resource directory other than "main")
-h, --help output usage information
如果你想创建一个比默认大小100更大的引导界面,你可以这样做:
yarn react-native generate-bootsplash assets/bootsplash_logo_original.png
--background-color=F5FCFF
--logo-width=300
--assets-path=assets
--flavor=main
我只是想确保你的logo质量足够高,这样你的bootsplash看起来仍然很好。