{"id":18356260,"url":"https://github.com/rainbowatcher/wasmup","last_synced_at":"2026-03-13T05:02:53.647Z","repository":{"id":250115846,"uuid":"830302856","full_name":"rainbowatcher/wasmup","owner":"rainbowatcher","description":"wasm pack, made easy","archived":false,"fork":false,"pushed_at":"2026-02-10T04:17:08.000Z","size":651,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-02-10T09:43:55.055Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/rainbowatcher.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-07-18T02:46:21.000Z","updated_at":"2026-02-10T04:17:12.000Z","dependencies_parsed_at":"2024-07-31T07:56:24.090Z","dependency_job_id":"924a478e-0229-4074-989c-a96ffbf10077","html_url":"https://github.com/rainbowatcher/wasmup","commit_stats":null,"previous_names":["rainbowatcher/wasmup"],"tags_count":30,"template":false,"template_full_name":"rainbowatcher/ts-cli-starter","purl":"pkg:github/rainbowatcher/wasmup","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rainbowatcher%2Fwasmup","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rainbowatcher%2Fwasmup/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rainbowatcher%2Fwasmup/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rainbowatcher%2Fwasmup/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rainbowatcher","download_url":"https://codeload.github.com/rainbowatcher/wasmup/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rainbowatcher%2Fwasmup/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30459293,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-13T03:55:51.346Z","status":"ssl_error","status_checked_at":"2026-03-13T03:55:33.055Z","response_time":60,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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-11-05T22:09:26.811Z","updated_at":"2026-03-13T05:02:53.630Z","avatar_url":"https://github.com/rainbowatcher.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/rainbowatcher/wasmup/ci.yml)](https://github.com/rainbowatcher/wasmup/actions)\n![GitHub License](https://img.shields.io/github/license/rainbowatcher/wasmup)\n[![NPM Version](https://img.shields.io/npm/v/wasmup)](https://www.npmjs.com/package/wasmup)\n\n# wasmup\n\nWasm build, made easy\n\n\u003e [!WARNING]\n\u003e It's in early development status, use in your own risk.\n\n## features\n\n- Build a set of code that can run seamlessly in Node.js, Deno, Bun, and browsers.\n- No setup needed, just use directly.\n- The generated package.json in pretty order.\n- Add parameter validation to functions.\n\n## Usage\n\nRequires Node.js `\u003e=20.19.0`.\n\n```sh\npnpm install -D wasmup\n```\n\n```jsonc\n{\n    // ...\n    \"scripts\": {\n        \"build\": \"wasmup build --clean .\",\n    },\n}\n```\n\n### Runtime usage (Node.js / Bun / Deno / Web)\n\nUse the same ESM API in all runtimes:\n\n```ts\nimport init, { hello_world } from \"your-wasm-package\"\n\nawait init()\nconsole.log(hello_world())\n```\n\nFor sync initialization:\n\n1. `initSync` is only supported in Node.js, Bun and Deno.\n2. `initSync` is not supported in browsers.\n\nFor browser deployment:\n\n1. Keep `index_bg.wasm` accessible by URL.\n2. `index_bg.wasm` should be deployed next to the generated JS entry (or with an equivalent URL mapping).\n\n### Configuration\n\nThe Wasmup configuration file may be named any of the following:\n\n- `wasmup.config.js`\n- `wasmup.config.cjs`\n- `wasmup.config.mjs`\n- `wasmup.config.ts`\n- `wasmup.config.mts`\n- `wasmup.config.cts`\n- `wasmup.config.json`\n\nIt should be placed in the root directory of your project and export an configuration objects. Here’s an example:\n\n```ts\nimport { defineConfig } from \"wasmup\"\n\nexport default defineConfig({\n    clean: true,\n    output: \"packages/toml-edit-js\",\n    scope: \"rainbowatcher\",\n})\n```\n\n### wasm-opt options\n\nyou can pass wasm-opt params by config in Cargo.toml, details ref to this link: [cargo-toml-configuration](https://rustwasm.github.io/docs/wasm-pack/cargo-toml-configuration.html)\n\n```toml\n[package.metadata.wasm-pack.profile.release]\nwasm-opt = [\n    # Optimize level 4\n    \"-O4\",\n    # Run passes to convergence, continuing while binary size decreases\n    \"--converge\",\n    \"--strip-debug\",\n    \"--strip-dwarf\",\n    # flattens out code, removing nesting\n    \"--flatten\",\n    # inline small functions\n    \"--inlining\",\n    # removes unreachable code\n    \"--dead-code-elimination\",\n    \"--minify-imports-and-exports-and-modules\",\n    # Grand Unified Flow Analysis\n    \"--gufa\",\n]\n```\n\n## License\n\n[MIT](./LICENSE) \u0026copy; Made by ❤️\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frainbowatcher%2Fwasmup","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frainbowatcher%2Fwasmup","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frainbowatcher%2Fwasmup/lists"}