Here's an example of a simple game implemented as a single HTML file using JavaScript:
This example sets up a canvas element on the page and allows the player to control a "player" object using touch events. The player's position is updated based on touch coordinates, and the game state is redrawn on the canvas repeatedly.
Please note that this is just a basic example and can be expanded to include more game mechanics, levels, scoring, etc., depending on your requirements.