{"id":22756618,"url":"https://github.com/yukimemi/nips","last_synced_at":"2026-04-28T22:31:31.052Z","repository":{"id":59680465,"uuid":"538488955","full_name":"yukimemi/nips","owner":"yukimemi","description":"Spinner library for Deno","archived":false,"fork":false,"pushed_at":"2022-09-24T00:39:40.000Z","size":9,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-05T16:43:01.014Z","etag":null,"topics":["deno","spinner"],"latest_commit_sha":null,"homepage":"https://deno.land/x/nips","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/yukimemi.png","metadata":{"files":{"readme":"README.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}},"created_at":"2022-09-19T12:23:21.000Z","updated_at":"2022-09-19T13:42:45.000Z","dependencies_parsed_at":"2022-09-19T19:51:20.474Z","dependency_job_id":null,"html_url":"https://github.com/yukimemi/nips","commit_stats":null,"previous_names":[],"tags_count":17,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yukimemi%2Fnips","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yukimemi%2Fnips/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yukimemi%2Fnips/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yukimemi%2Fnips/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/yukimemi","download_url":"https://codeload.github.com/yukimemi/nips/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246290569,"owners_count":20753724,"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":["deno","spinner"],"created_at":"2024-12-11T07:14:30.648Z","updated_at":"2026-04-28T22:31:26.033Z","avatar_url":"https://github.com/yukimemi.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# nips\nSpinner library for Deno\n\n## Demo\n\n```sh\ndeno run -A https://deno.land/x/nips/example.ts\n```\n\n## Example\n\n```typescript\nimport { delay } from \"https://deno.land/std@0.156.0/async/delay.ts\";\nimport * as colors from \"https://deno.land/std@0.156.0/fmt/colors.ts\";\nimport { Nip, Nips } from \"https://deno.land/x/nips/mod.ts\";\n\nconst dots = new Nip(\n  [\"⠋\", \"⠙\", \"⠹\", \"⠸\", \"⠼\", \"⠴\", \"⠦\", \"⠧\", \"⠇\", \"⠏\"].map(colors.cyan),\n  [\"✔\"].map(colors.green),\n  [\"✘\"].map(colors.red),\n);\n\nconst arc = new Nip(\n  [\"◜\", \"◠\", \"◝\", \"◞\", \"◡\", \"◟\"].map(colors.magenta),\n  [\"○\"].map(colors.green),\n  [\"×\"].map(colors.red),\n);\n\nconst arrow = new Nip(\n  [\"←\", \"↖\", \"↑\", \"↗\", \"→\", \"↘\", \"↓\", \"↙\"].map(colors.yellow),\n  [\"○\", \"◎\", \"●\"].map(colors.green),\n  [\"×\", \"✘\", \"✖\"].map(colors.red),\n);\n\nconst nips = new Nips({\n  interval: 70,\n  n: { dots, arc, arrow },\n});\n\nnips.start(\"${this.n.dots.spin()} start spin ...\");\nawait delay(2000);\nnips.stop(\"${this.n.dots.spin()} stop spin ...\");\nawait delay(2000);\nconst variableText = \"This is variable text\";\nnips.start(`\\${this.n.dots.spin()} ${variableText}`);\nawait delay(2000);\nnips.start(\"${this.n.dots.fail()} fail spin !\");\nawait delay(2000);\nnips.start(\"${this.n.dots.spin()} restart spin ...\");\nawait delay(2000);\nnips.start(\n  \"${this.n.dots.spin()} 1st spin ...\\n${this.n.arc.spin()} 2nd spin ...\",\n);\nawait delay(2000);\nnips.start(\n  \"${this.n.dots.spin()} 1st spin ...\\n${this.n.arc.spin()} 2nd spin ...\\n${this.n.arrow.spin()} 3rd spin ...\",\n);\nawait delay(2000);\nnips.stop(\n  \"${this.n.dots.success()} 1st spin success !\\n${this.n.arc.fail()} 2nd spin fail ...\\n${this.n.arrow.spin()} 3rd spin ...\",\n);\nawait delay(2000);\nnips.clear(2);\nnips.start(\n  \"${this.n.arc.spin()} 2nd spin restart !\\n${this.n.arrow.spin()} 3rd spin restart !\",\n);\nawait delay(2000);\nnips.start(\n  \"${this.n.arc.spin()} 2nd spin ...\\n${this.n.arrow.spin()} 3rd spin ...\",\n);\nawait delay(2000);\nnips.start(\n  \"${this.n.arc.success()} 2nd spin success !\\n${this.n.arrow.success()} 3rd spin success (not stop)!\",\n);\nawait delay(2000);\nnips.stop(\n  \"${this.n.arc.success()} 2nd spin success !\\n${this.n.arrow.success()} 3rd spin success !\\n\",\n);\nnips.stop(\"${this.n.dots.success()} ALL SUCCESS !\\n\");\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyukimemi%2Fnips","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyukimemi%2Fnips","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyukimemi%2Fnips/lists"}