They can be played directly in the browser, or you can use tools like Tauri to package them into desktop applications.
Libraries/Engines/Frameworks
- KaboomJS - this is a good place to start if you kinda know JS and want to make an action game
(I used it for Global Game Jam and thought it was neat!) - Phaser - probably the most popular JS game library
(I made a competitive clicker with Phaser) - BabylonJS - I haven't used it, but it's 3D!