{"id":21070844,"url":"https://github.com/raxjs/universal-api","last_synced_at":"2025-05-16T15:09:00.062Z","repository":{"id":41066994,"uuid":"209819048","full_name":"raxjs/universal-api","owner":"raxjs","description":"Universal apis for web and miniapps.","archived":false,"fork":false,"pushed_at":"2023-05-18T02:59:59.000Z","size":7971,"stargazers_count":270,"open_issues_count":27,"forks_count":62,"subscribers_count":17,"default_branch":"master","last_synced_at":"2025-04-28T21:04:39.286Z","etag":null,"topics":["mini-program","miniapp","rax","universal-apis","wechat","wechat-mini-program"],"latest_commit_sha":null,"homepage":"https://universal-api.js.org/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/raxjs.png","metadata":{"files":{"readme":"README.en-US.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2019-09-20T15:08:00.000Z","updated_at":"2025-03-17T10:24:33.000Z","dependencies_parsed_at":"2024-06-18T13:53:28.695Z","dependency_job_id":null,"html_url":"https://github.com/raxjs/universal-api","commit_stats":{"total_commits":449,"total_committers":33,"mean_commits":"13.606060606060606","dds":0.7861915367483296,"last_synced_commit":"8912b294669bf5ed5a74135ddcd0a57a07c7d50f"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raxjs%2Funiversal-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raxjs%2Funiversal-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raxjs%2Funiversal-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raxjs%2Funiversal-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/raxjs","download_url":"https://codeload.github.com/raxjs/universal-api/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253309339,"owners_count":21887973,"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":["mini-program","miniapp","rax","universal-apis","wechat","wechat-mini-program"],"created_at":"2024-11-19T18:48:35.561Z","updated_at":"2025-05-16T15:08:55.047Z","avatar_url":"https://github.com/raxjs.png","language":"TypeScript","readme":"\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://rax.js.org/docs/guide/about-miniapp\"\u003e\n    \u003cimg alt=\"Rax\" src=\"https://user-images.githubusercontent.com/677114/59907138-e99f7180-943c-11e9-8769-07021d9fe1ca.png\" width=\"66\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\nUni API is a cross-terminal API solution that supports applets and web containers.\n\u003c/p\u003e\n\n---\n\n🎉 **Multi-container support** Currently supports Web, WeChat Mini Programs, Toutiao Mini Programs, Ali Mini Programs, Baidu Smart Programs and Kuaishou Mini Programs\n🐂 **Rich API** Cover 90+ API implementations\n😯 **Complete documentation** Provide bilingual documents and rich samples\n0️⃣ **No framework dependency** No framework dependency, pure native implementation, compatible with any framework\n🚀 **Extreme volume** Support on-demand loading, eliminate useless code according to the environment\n👍🏻 **Easy to use, fast access** Provide a complete Typescripts statement, so you can get rid of the documentation and immerse yourself in programming\n\n## Quick start\n\n\u003e Take @uni/toast as an example\n\n```bash\n$ npm install @uni/toast\n```\n\n```js\nimport { showToast } from '@uni/toast';\n\n// string\nshowToast('Hi');\n\n// object\nshowToast({\n  content: 'hello',\n  type: 'success',\n  duration: 1000,\n  success: () =\u003e {\n    console.log('toast')\n  }\n});\n\n// promise\nshowToast({\n  content: 'hello',\n  type: 'success',\n  duration: 1000,\n}).then(() =\u003e {});\n```\n\n## Docs\nOfficial site: [https://universal-api.js.org/](https://universal-api.js.org/)\n\n## Example\n\u003cdiv style=\"display: flex;margin-bottom: 200px;\"\u003e\n  \u003cdiv\u003e\n    \u003cdiv style=\"width: 200px;height: 250px;\"\u003e\n      \u003cimg src=\"https://img.alicdn.com/imgextra/i1/O1CN01upA1bP1CxpGb8qLPp_!!6000000000148-0-tps-662-662.jpg\" width=\"200\" height=\"200\" /\u003e\n    \u003c/div\u003e\n    \u003cdiv style=\"text-align: center;\"\u003eWechat MiniProgram\u003c/div\u003e\n  \u003c/div\u003e\n  \u003cdiv style=\"margin-left: 30px;\"\u003e\n    \u003cdiv style=\"line-height: 0;\"\u003e\n      \u003cimg src=\"https://gw.alicdn.com/imgextra/i3/O1CN01Ca6t2Q2AEpIXh4r0u_!!6000000008172-0-tps-1540-1906.jpg\" width=\"200\" height=\"250\" /\u003e\n    \u003c/div\u003e\n    \u003cdiv style=\"text-align: center;\"\u003eAlibaba MiniApp\u003c/div\u003e\n  \u003c/div\u003e\n\u003c/div\u003e\n\n## Contribute code\nPlease read [Rax Contribution Code Guide](https://github.com/alibaba/rax/wiki/CONTRIBUTING), Understand the basic specifications.\n\n### Get started\n\n```\n$ git clone git@github.com:raxjs/universal-api.git\n$ npm install\n$ npm run build\n```\n\n### Debug API\nTake @uni/toast as an example:\n\n```\n$ npm run build toast\n$ npm run build:demo\n$ cd demos\n$ npm i\n$ npm run start # 启动项目，打开小程序 IDE 进行调试\n```\n\n## Protocol\n\n[BSD License](https://github.com/raxjs/miniapp/blob/master/LICENSE)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraxjs%2Funiversal-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fraxjs%2Funiversal-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraxjs%2Funiversal-api/lists"}