You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
From playing around with this (very cool btw), I noticed that if I attempted to launch my app from a directory other than where index.html resides, "/" would fail to be resolved, whereas if I specified "/index.html" it would be resolved fine.
This appears to be caused due to ezwebframe:handle/2, the logic is different when resolving "/" than any other page. This may be intentional (it makes sense to launch from wherever index.html is located after all), but it is surprising to see -
mapped to:"/location/where/index/is/for/realsies/located"
serve_abs:"index.html"
*** no page called "index.html"
when hitting "/", and have it load just fine when hitting "/index.html".
The text was updated successfully, but these errors were encountered:
Whoops. Came to look, clicked the wrong button. :P Was going to comment, the top level makefile then runs the makefile in /demos, which executes erl, and that is also where index.html is.
If erl is launched somewhere other than where index.html lives, even if the dispatcher knows to point to that location properly (I had erl executing from /ebin, but a /web folder as a sort of catch-all for client side things, and that was where index.html was), that information is ignored due to the different logic for resolving "/". But "/index.html" worked fine, since that didn't match "/", and instead fell to the _ case clause, which passes in the Env#env.dispatch path.
From playing around with this (very cool btw), I noticed that if I attempted to launch my app from a directory other than where index.html resides, "/" would fail to be resolved, whereas if I specified "/index.html" it would be resolved fine.
This appears to be caused due to ezwebframe:handle/2, the logic is different when resolving "/" than any other page. This may be intentional (it makes sense to launch from wherever index.html is located after all), but it is surprising to see -
mapped to:"/location/where/index/is/for/realsies/located"
serve_abs:"index.html"
*** no page called "index.html"
when hitting "/", and have it load just fine when hitting "/index.html".
The text was updated successfully, but these errors were encountered: