{"id":13445842,"url":"https://github.com/sindresorhus/cli-spinners","last_synced_at":"2025-05-13T00:07:09.314Z","repository":{"id":39954281,"uuid":"53072449","full_name":"sindresorhus/cli-spinners","owner":"sindresorhus","description":"Spinners for use in the terminal","archived":false,"fork":false,"pushed_at":"2024-09-07T13:13:36.000Z","size":328,"stargazers_count":2512,"open_issues_count":3,"forks_count":115,"subscribers_count":20,"default_branch":"main","last_synced_at":"2025-05-13T00:06:58.499Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/sindresorhus.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":".github/security.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"sindresorhus","open_collective":"sindresorhus","buy_me_a_coffee":"sindresorhus","custom":"https://sindresorhus.com/donate"}},"created_at":"2016-03-03T18:13:57.000Z","updated_at":"2025-05-12T11:27:51.000Z","dependencies_parsed_at":"2024-01-16T04:30:13.517Z","dependency_job_id":"3d14a023-e83a-4c55-b0d2-0f14ab46985c","html_url":"https://github.com/sindresorhus/cli-spinners","commit_stats":{"total_commits":85,"total_committers":34,"mean_commits":2.5,"dds":"0.42352941176470593","last_synced_commit":"a01e4cf1235e1425f0243f36887db168cf710279"},"previous_names":[],"tags_count":27,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sindresorhus%2Fcli-spinners","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sindresorhus%2Fcli-spinners/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sindresorhus%2Fcli-spinners/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sindresorhus%2Fcli-spinners/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sindresorhus","download_url":"https://codeload.github.com/sindresorhus/cli-spinners/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253843215,"owners_count":21972873,"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-07-31T05:00:40.468Z","updated_at":"2025-05-13T00:07:09.228Z","avatar_url":"https://github.com/sindresorhus.png","language":"JavaScript","readme":"# cli-spinners\n\n\u003e 70+ spinners for use in the terminal\n\n\u003cp align=\"center\"\u003e\n\t\u003cbr\u003e\n\t\u003cimg width=\"700\" src=\"screenshot.svg\"\u003e\n\t\u003cbr\u003e\n\t\u003cbr\u003e\n\u003c/p\u003e\n\nThe list of spinners is just a [JSON file](spinners.json) and can be used wherever.\n\nYou probably want to use one of these spinners through the [`ora`](https://github.com/sindresorhus/ora) package.\n\n## Install\n\n```sh\nnpm install cli-spinners\n```\n\n## Usage\n\n```js\nimport cliSpinners from 'cli-spinners';\n\nconsole.log(cliSpinners.dots);\n/*\n{\n\tinterval: 80,\n\tframes: ['⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏']\n}\n*/\n```\n\n## Preview\n\nThe header GIF is outdated. See all the [spinner at once](https://jsfiddle.net/sindresorhus/2eLtsbey/embedded/result/) or [one at the time](https://asciinema.org/a/95348?size=big).\n\n## API\n\n### cliSpinners\n\nEach spinner comes with a recommended `interval` and an array of `frames`.\n\n[See the spinners.](spinners.json)\n\n### randomSpinner()\n\nGet a random spinner.\n\n```js\nimport {randomSpinner} from 'cli-spinners';\n\nconsole.log(randomSpinner());\n/*\n{\n\tinterval: 80,\n\tframes: ['⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏']\n}\n*/\n```\n\n## Related\n\n- [ora](https://github.com/sindresorhus/ora) - Elegant terminal spinner\n- [CLISpinner](https://github.com/kiliankoe/CLISpinner) - Terminal spinners for Swift\n- [py-spinners](https://github.com/ManrajGrover/py-spinners) - Python port\n- [spinners](https://github.com/FGRibreau/spinners) - Terminal spinners for Rust\n- [go-spinners](https://github.com/gabe565/go-spinners) - Go port\n","funding_links":["https://github.com/sponsors/sindresorhus","https://opencollective.com/sindresorhus","https://buymeacoffee.com/sindresorhus","https://sindresorhus.com/donate"],"categories":["第三方库介绍","JavaScript","License"],"sub_categories":["脚手架","Injecting spinner into a function"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsindresorhus%2Fcli-spinners","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsindresorhus%2Fcli-spinners","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsindresorhus%2Fcli-spinners/lists"}