Tuesday, May 8, 2018

generateAppendClassName: CSS module is undefined

Leave a Comment

I have a React v15 web app that runs fine at localhost. Yet when I deploy it to GitHub pages, I have a CSS module is undefined error:

enter image description here

I've set up a test repo for this issue: https://github.com/ZeningQu/test-repo/tree/master

If you clone the repo and run yarn start, you should be able to see the load-data-pane component: enter image description here

But when you do yarn run deploy, the GitHub page is basically empty:

enter image description here

More info:

1 Answers

Answers 1

I couldn't get your repo to work in my local machine. However, I've had problems with deploying React application before. One trick I learnt was to put <base href="/"> in the <head> tag in repo/public/index.html. Maybe you can try that and see if it works for you.

If You Enjoyed This, Take 5 Seconds To Share It

0 comments:

Post a Comment