Sure! Here's an example of a simple platformer game that includes player movement, gravity, and enemies. The game is implemented as a single HTML file and contains JavaScript code enclosed within script tags.
This game includes a player that can move left and right using the left and right arrow keys. The player can also jump by pressing the spacebar. Gravity is applied, making the player fall back down after jumping. There are two enemies (red blocks) in the game, and colliding with them will trigger a game over. The game will restart automatically after a collision.