hupe1980 / gatsby-theme-material-ui

Gatsby theme for Material-UI
MIT License
100 stars 44 forks source link

Suggestion to remove dependency gatsby-plugin-webfonts #103

Open slightly-blue opened 1 year ago

slightly-blue commented 1 year ago

I would like to suggest the gatsby-plugin-webfonts dependecy to be removed from this theme and give users the freedom to load fonts with another plugin like gatsby-omni-font-loader.

I constantly run into this error,

ERROR #11321  PLUGIN
"gatsby-plugin-webfonts" threw an error while running the onPreBootstrap lifecycle:

read ECONNRESET
  Error: read ECONNRESET
  - stream_base_commons:217 TLSWrap.onStreamRead
    node:internal/stream_base_commons:217:20
ERROR 

Module not found: Error: Can't resolve '/.cache/webfonts/webfonts.css' 
in 'C:\Users\<firstname lastname>\Documents\GitHub\<project name>\node_modules\gatsby-plugin-webfonts'

It randomly appears over 50% of the time and causes builds to fail. I don't appear to be the only one having this issue .

My current workaround is to just edit the theme in node_modules to not include the dependency but that is not a lasting fix.