TypeError: fullscreen error HTML5

Hello! When I turn on the full screen in the html assembly, an error appears. How do I make a full-screen game automatically?

Снимок экрана 2022-04-15 в 12.19.25

Uncaught (in promise) TypeError: fullscreen error
at Object.requestFullScreen (:1:220693)
at _glfwOpenWindow (:1:227721)
at 00a09e3a:0x15238d
at 00a09e3a:0x18a97a
at 00a09e3a:0x188d7c
at 00a09e3a:0x189887
at 00a09e3a:0x10a523
at 00a09e3a:0xf7d2b
at Module._main (:1:257408)
at Object.callMain (:1:261864)

I’m not sure why there is a callstack/error.

Note however, that it’s unlikely to work “from the start”, as such events needs to be initiated by user events (i.e. a click of a button).

1 Like

Thanks for the answer, I read about it. But on unity it can be done, the first click on the screen automatically translates to full screen, how to do it in Defold? Is there a simple solution?

This is not for HTML5, uncheck it and the error will be gone.

2 Likes