Are there any limitations with just HTML files with no backend?

Hi! I had a HTML file that was working locally, got it working on Glitch, and then a couple of hours later it goes down with the failed to start application error message.

So I decided to try to just get something up, so I cleared out the whole file, deleted all the other files, and just did a simple:

<!DOCTYPE html>

I still get the failed to start application error message. I did notice in the logs this error message, but this message also showed when the previous HTML file was rendering:

SyntaxError: Unexpected end of JSON input
    at Object.parse (native)
    at /etc/service/watcher/source/
    at ChildProcess.exithandler (child_process.js:197:7)
    at emitTwo (events.js:106:13)
    at ChildProcess.emit (events.js:191:7)
    at maybeClose (internal/child_process.js:877:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)

Any idea what might be causing this? Are there limitations with HTML files with no backend I should know about? Thanks!

there are no known limitations, but you’ll still need to keep the server.js and package.json files included with the default welcome project to set up static file serving. If you give us the name of the project we’ll look into it?

This might be useful:!/minimal-http-server

I was wondering if you need them to keep it working. It worked for a while without, so it made me question it.

fast-drive is where I was testing this out.

ya you need them because otherwise the server won’t know how to serve the files

(the lower level you go, the more power you’ve got, but also the more you realize how dumb computers actually are)

Hope that helps

1 Like

Definitely helps!

If you happen to know, why did it work for a while? Like how did it know what files to serve and then didn’t?

possibly due to the browser caching a working copy of the html? This might happen if you did the html, opened the app in your browser (when the cache gets created), then deleted the server files.