Shopify themes, liquid, logos, and UX
Theme fonts are not pulling when using Shopify CLI.
Expected behavior
Theme font's need to be downloaded.
Actual behavior
┃ ERROR get assets/Arial-Bold.eot: wrong number of arguments (given 4, expected 2..3)
┃ ERROR get assets/Arial-Bold.ttf: wrong number of arguments (given 4, expected 2..3)
┃ ERROR get assets/Arial-Bold.woff2: wrong number of arguments (given 4, expected 2..3)
┃ ERROR get assets/Arial-Bold.woff: wrong number of arguments (given 4, expected 2..3)
┃ ERROR get assets/Arial.eot: wrong number of arguments (given 4, expected 2..3)
┃ ERROR get assets/Arial.ttf: wrong number of arguments (given 4, expected 2..3)
┃ ERROR get assets/Arial.woff2: wrong number of arguments (given 4, expected 2..3)
┃ ERROR get assets/Arial.woff: wrong number of arguments (given 4, expected 2..3)
Steps to reproduce the problem
hey, did you find a solution for this?
No, this is broken and no one is answering here, even in Github
Ok I found a workaround at least:
It is not possible to pull fonts from shopify to local. I think that is by purpose, because they dont want you to upload fonts other then those they provide. They want you to use a CDN.
So either you are using Adobe Typekit, Font Awesome oder Google Fonts or some other font library which has its own CDN you can use. If so you can get your link there, for example I want to use the Google Font "Alata" which is not provided in Shopify. So I went to Google Fonts, got me the link to Google CDN and inserted this at the top of my custom CSS file. Works!
Or if you have a font that is not available on a CDN already you can host it somewhere else yourself or use a CDN service (maybe cloudflare?) to do so. I haven't tried to do that but I'm sure its possible and there are tutorials for that over the internet.
If you're running a international website I would recommend not to host fonts on your own server, but on a CDN, as it will likely slow down your page.
If somebody figures this out it would be nice to share a little how-to here ...
Hope this helps
Are you ready to take your business to the next level? Look no further than the latest ...
By SarahF_Shopify Apr 15, 2024We’re keeping the ball rolling to make sure you’re always ahead of the game. So buckle ...
By JasonH Apr 8, 2024Portrait of Stephen positioned next to an image of planet Earth, with the Stephen's World ...
By JasonH Mar 18, 2024