Search code examples
javascripthtmlcodesandbox

codesandbox.io unable to point to anything expcet "index.html"


Trying to setup a vanilla JS on codesandbox.io, when I change the name of the index file, the app no longer can see the HTML at all and throws an error. I must be missing something here, why can I not change the name? In the link here, I have a very basic reproduction of this issue.


Solution

  • The html page can be loaded by navigating to it in the mini browser:

    enter image description here

    When sharing the sandbox a default url can be configured: enter image description here

    By choosing other options: enter image description here

    and entering the url: enter image description here

    and then sharing it: enter image description here

    The result: https://codesandbox.io/s/agitated-morning-j9fvl?fontsize=14&initialpath=notIndex.html