Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add monorepo documentation for specifying iconFontsDir #1183

Closed
jgornick opened this issue Jun 8, 2020 · 6 comments · Fixed by #1476
Closed

Add monorepo documentation for specifying iconFontsDir #1183

jgornick opened this issue Jun 8, 2020 · 6 comments · Fixed by #1476

Comments

@jgornick
Copy link

jgornick commented Jun 8, 2020

Environment

macOS 10.15.4
Android
6.6.0

Description

In a monorepo setup, icons do not appear to render and show a rectangle with lines through them.

Android Emulator

Reproducible Demo

Using a monorepo setup and with yarn workspaces, the node_modules are installed at the root of the monorepo. The path to the icons needs to be updated with the new relative path:

project.ext.vectoricons = [
    iconFontsDir: "../../../../node_modules/react-native-vector-icons/Fonts"
]

apply from: file("../../../../node_modules/react-native-vector-icons/fonts.gradle");
@ReeVicente
Copy link

I have this issue, please help us :'(

@robclouth
Copy link

@jgornick hey joe, sorry to bother you. i'm struggling to get the icons to show on android with a monorepo setup. I've added the iconFontsDir, and looking inside the apk the fonts are getting copied to assets/fonts. But they still don't show up in the app. Is there anything else I need to change? I've tried copying them manually too, which doesn't work either. Any hints would be most welcome.

@jgornick
Copy link
Author

jgornick commented Nov 10, 2020

Sorry @robclouth and @ReeVicente, the only help I can provide is in the solution I included above by specifying the iconFonsDir and applying the fonts.gradle. Just make sure the (relative) paths are correct.

@robclouth
Copy link

robclouth commented Nov 10, 2020 via email

@oskarhertzman
Copy link

Was ripping my hair out, this worked, thanks!

@dhatGuy
Copy link

dhatGuy commented Aug 28, 2022

I figured it out. In expo bare workflow you need to manually import the fonts with expo-font. Two days down the drain because of that...🤦🏻‍♂️ Thanks for replying though!

On Tue, 10 Nov 2020, 20:15 Joe Gornick, @.***> wrote: Sorry @robclouth https://github.com/robclouth and @ReeVicente https://github.com/ReeVicente, the only help I can provide is in the solution I included above by specifying the iconFonsDir and applying the fonts.gradle. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#1183 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJP3IQDONSMM5UOJGGBFX3SPGGMFANCNFSM4NX5SBVQ .

How did you do that, please?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants