As an AI text-based model, I can provide you with a simple text-based version of the Pac-Man game that can be played in a web browser. Here's a playable sample game implemented with JavaScript within a single HTML file:
You can copy the above code into a single HTML file (e.g., `pacman.html`) and open it in a web browser. The game will be rendered as a grid where "P" represents Pac-Man, "#" represents walls, and "." represents empty spaces. Use the arrow keys on your keyboard to move Pac-Man around the map and avoid the walls.
Note: This is a very basic text-based version of Pac-Man and may not include all the features of the original game. It serves as a starting point, and you can enhance it further as per your requirements.