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
Having asset.exists([String path]) would be a good API. This only issue is that if the underlying file system is changed between a call to exists and server or read the builtin 404 could still be returned. However for a deployed server the content in build/web is not supposed to change.
Saying that build/web is not supposed to change can also make it possible to cache the result of exists calls and potentially what is read by server or read as well.
I want to render my own
404
pages, butAssets
doesn't give me a clean way to do that.It would be great if one of those could be implemented:
assets.fileExists()
function, so I can check if the file existsassets.serve()
so it throws an exception instead of responding with404
itself.What I'm doing to get this working is:
which obviously is less than ideal.
The text was updated successfully, but these errors were encountered: