{"id":13671629,"url":"https://github.com/shekohex/rust-wasm-hotreload","last_synced_at":"2025-04-13T21:41:08.506Z","repository":{"id":42707959,"uuid":"293352977","full_name":"shekohex/rust-wasm-hotreload","owner":"shekohex","description":"PoC Using WASM Modules as Hot-Reloading Logic from Rust.","archived":false,"fork":false,"pushed_at":"2024-06-16T15:02:12.000Z","size":33,"stargazers_count":45,"open_issues_count":2,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-27T12:02:24.793Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/shekohex.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":"2020-09-06T20:03:18.000Z","updated_at":"2025-02-01T15:55:19.000Z","dependencies_parsed_at":"2024-10-03T12:23:37.976Z","dependency_job_id":"9daed00c-7fce-46df-b121-5d1593f8a197","html_url":"https://github.com/shekohex/rust-wasm-hotreload","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shekohex%2Frust-wasm-hotreload","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shekohex%2Frust-wasm-hotreload/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shekohex%2Frust-wasm-hotreload/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shekohex%2Frust-wasm-hotreload/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shekohex","download_url":"https://codeload.github.com/shekohex/rust-wasm-hotreload/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248788859,"owners_count":21161726,"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-02T09:01:14.996Z","updated_at":"2025-04-13T21:41:08.449Z","avatar_url":"https://github.com/shekohex.png","language":"Rust","funding_links":[],"categories":["Rust"],"sub_categories":[],"readme":"## Rust + WASM = 🔥 Hot-Reload 🔥\n\nA PoC of using WebAssemply as a Hot-Reloadable Code logic at Runtime without restarting the Host Process.\n\nfor a simple demo see this [tweet](https://twitter.com/ShekoHex/status/1302973994417651714)\n\n## Try it\n\nFirst make sure you have both Rust and NodeJS (also NPM) installed.\n\n1. Clone\n\n```sh\n$ git clone https://github.com/shekohex/rust-wasm-hotreload\n```\n\n2. Build\n\n```sh\n$ npm install\n$ npm run asbuild:optimized\n$ cargo build\n```\n\n3. Run\n\nIn one terminal, start build and watch for changes to our AssemplyScript File.\n\n```sh\n$ npm run watch\n```\n\nin another terminal simply run\n\n```sh\n$ cargo run\n```\n\nNow, just change the logic in the `assembly/index.ts` file and watch the magic happen :).\n\n### Use Cases\n\nThis Project uses [Rust](https://www.rust-lang.org/) and [AssemblyScript](http://assemblyscript.org/) to address these use cases:\n\n- Scripting (by extending your program with other functionality by using WASM files).\n- GameDev (again, it would be useful to add some game logic like (NPCs, Quests, ...etc) as WASM module for easy changes and fast development)\n- User-Land Extentions.\n- Your Case?\n\n### FAQ\n\n1. Why use [AssemplyScript](https://www.assemblyscript.org/) rather than Rust for WASM?\n\nWell, let's be honest here... `rustc` compilation-time would kill the whole idea about _Fast Hot Reloading™_, and while AssemblyScript compiles so fast, it emits smaller code than `rustc` would and yet it has almost the same performance, and that's why it's a better option for writing code that compiles to WASM.\n\n### Contributing\n\nWant to join us? take a look at some of these issues:\n\n- [Issues labeled \"good first issue\"][good-first-issue]\n- [Issues labeled \"help wanted\"][help-wanted]\n\n[good-first-issue]: https://github.com/shekohex/rust-wasm-hotreload/labels/good%20first%20issue\n[help-wanted]: https://github.com/shekohex/rust-wasm-hotreload/labels/help%20wanted\n\n### License\n\n\u003csup\u003e\nLicensed under \u003ca href=\"LICENSE\"\u003eMIT license\u003c/a\u003e.\n\u003c/sup\u003e\n\n\u003cbr/\u003e\n\n\u003csub\u003e\nUnless you explicitly state otherwise, any contribution intentionally submitted\nfor inclusion in this crate by you, as defined in the MIT license, shall\nbe licensed as above, without any additional terms or conditions.\n\u003c/sub\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshekohex%2Frust-wasm-hotreload","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshekohex%2Frust-wasm-hotreload","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshekohex%2Frust-wasm-hotreload/lists"}