Custom local svg is not showing in BotttomNavigation - How to pass it in routes icon #3129
Answered
by
Krithik-Shailesh
Krithik-Shailesh
asked this question in
Q&A
|
I have a local svg file but when I put it as a component in routes icon it is not getting rendered.
|
Answered by
Krithik-Shailesh
Mar 23, 2022
Replies: 1 comment
|
I solved it using the renderIcon prop, I passed all the icons through a renderIcon function.
|
0 replies
Answer selected by
Krithik-Shailesh
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I solved it using the renderIcon prop, I passed all the icons through a renderIcon function.
const renderIcon = BottomNavigation.SceneMap({ purchases: PurchaseIcon, sales: SalesIcon, tools: ToolsIcon, apps: AppsIcon, settings: SettingsIcon })Where
PurchaseIconwasconst PurchaseIcon = () => <PurchasesLogo/>and the others like SalesIcon,..etc was similar to this.