Thanks!
I already had more convenient mouse controls in place but it turned out PGE3 doesn't support repositioning the cursor in an Emscripten environment, which would be needed for mouse grabbing, so the arrow keys are a bit of a band-aid solution here.