{"id":13569726,"url":"https://github.com/hajimehoshi/wasmserve","last_synced_at":"2025-04-05T14:09:49.311Z","repository":{"id":42395479,"uuid":"140020861","full_name":"hajimehoshi/wasmserve","owner":"hajimehoshi","description":"An HTTP server for testing Wasm","archived":false,"fork":false,"pushed_at":"2024-09-01T08:43:22.000Z","size":36,"stargazers_count":248,"open_issues_count":2,"forks_count":26,"subscribers_count":7,"default_branch":"main","last_synced_at":"2024-10-10T17:24:15.844Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hajimehoshi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-07-06T19:02:51.000Z","updated_at":"2024-10-07T19:14:08.000Z","dependencies_parsed_at":"2023-11-29T03:23:43.898Z","dependency_job_id":"cbab96de-1c80-4b78-8db3-1c8a4aa1b262","html_url":"https://github.com/hajimehoshi/wasmserve","commit_stats":{"total_commits":60,"total_committers":7,"mean_commits":8.571428571428571,"dds":"0.16666666666666663","last_synced_commit":"a2f9d4ea4bc1095d3e4350c36f68775c459dbb89"},"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hajimehoshi%2Fwasmserve","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hajimehoshi%2Fwasmserve/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hajimehoshi%2Fwasmserve/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hajimehoshi%2Fwasmserve/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hajimehoshi","download_url":"https://codeload.github.com/hajimehoshi/wasmserve/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247345856,"owners_count":20924102,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T14:00:43.336Z","updated_at":"2025-04-05T14:09:49.285Z","avatar_url":"https://github.com/hajimehoshi.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"# WasmServe\n\nAn HTTP server to test GOOS=js/GOARCH=wasm\n\n## Sponsors\n\nWasmServe is sponsored by [SourceGraph](https://sourcegraph.com/).\n\n## Installation\n\n```sh\ngo install github.com/hajimehoshi/wasmserve@latest\n```\n\n## Usage\n\n```\nUsage of wasmserve\n  -allow-origin string\n        Allow specified origin (or * for all origins) to make requests to this server\n  -http string\n        HTTP bind address to serve (default \":8080\")\n  -overlay string\n        Overwrite source files with a JSON file (see https://pkg.go.dev/cmd/go for more details)\n  -tags string\n        Build tags\n```\n\n## Trigger Refresh\n\nOnce the browser loads the page, you can trigger a reload by making a call to teh server at `/_notify`, like this:\n\n```sh\ncurl localhost:8080/_notify\n```\n\nThis will make the browser reload. You can add this command to a build script or to an IDE command, to have the browser automatically update without leaving your IDE.\n\n## Example\n\nRunning a remote package\n\n```sh\nwasmserve github.com/hajimehoshi/wasmserve/example\n```\n\nAnd open `http://localhost:8080/` on your browser.\n\n## Example 2\n\nRunning a local package\n\n```sh\ngit clone https://github.com/hajimehoshi/ebiten # This might take several minutes.\ncd ebiten\nwasmserve ./examples/sprites\n```\n\nAnd open `http://localhost:8080/` on your browser.\n\n## Known issue with Windows Subsystem for Linux (WSL)\n\nThis application sometimes does not work under WSL, due to bugs in WSL, see https://github.com/hajimehoshi/wasmserve/issues/5 for details.\n\n## Tips\n\n* If you want to change the working directory to serve, you can use cd with parentheses:\n\n```\n(cd /path/to/working/dir; wasmserve github.com/yourname/yourpackage)\n```\n\n* To trigger a browser reload from a script, make a call to `/_notify`, like this:\n\n```sh\ncurl http://localhost:8080/_notify\n```\nThis will make the browser refresh the page.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhajimehoshi%2Fwasmserve","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhajimehoshi%2Fwasmserve","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhajimehoshi%2Fwasmserve/lists"}