Search code examples
javascriptreactjsmaterializecodesandbox

Does Codesandbox,io remove the public directory from REACT apps & Why does it work without it?


I have been working with codesandbox.io and react and updating github from codesandbox. Today I tried to pull it down locally onto my machine (and install it) and work on it and realized two things.

  1. It didn't work
  2. There was no public directory in codesandbox and github, so no index.html but the app works in codesandbox.

So I have 2 questions 1. Does codesandbox.io remove the public directory or was it me? 2. If it was me why does my app still work in codesandbox.io

My Codesandbox is here https://codesandbox.io/s/wiki-mogpb?fontsize=14&hidenavigation=1&theme=dark


Solution

  • I was being stupid!

    Looks like I moved the public directory into my CSS folder and it was rendering from there successfully.

    Thats probably why its not working when i pull it down. Sounds like codesandbox is finding the file regardless of where it is!