{"id":21522174,"url":"https://github.com/hugoalh-studio/shuffle-array-js","last_synced_at":"2025-07-16T07:31:02.716Z","repository":{"id":175792401,"uuid":"654476508","full_name":"hugoalh-studio/shuffle-array-js","owner":"hugoalh-studio","description":"A JavaScript module to shuffle the array's indexes.","archived":false,"fork":false,"pushed_at":"2024-03-31T00:26:51.000Z","size":411,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-04-01T13:01:43.532Z","etag":null,"topics":["array","javascript","js","shuffle"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hugoalh-studio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":".github/CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":".github/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-06-16T08:02:15.000Z","updated_at":"2024-03-05T04:28:01.000Z","dependencies_parsed_at":null,"dependency_job_id":"94cd02eb-5848-476e-865d-1b6e7d794904","html_url":"https://github.com/hugoalh-studio/shuffle-array-js","commit_stats":null,"previous_names":["hugoalh-studio/shuffle-array-nodejs","hugoalh-studio/shuffle-array-js"],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hugoalh-studio%2Fshuffle-array-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hugoalh-studio%2Fshuffle-array-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hugoalh-studio%2Fshuffle-array-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hugoalh-studio%2Fshuffle-array-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hugoalh-studio","download_url":"https://codeload.github.com/hugoalh-studio/shuffle-array-js/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":226112989,"owners_count":17575438,"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":["array","javascript","js","shuffle"],"created_at":"2024-11-24T01:09:31.711Z","updated_at":"2024-11-24T01:09:32.402Z","avatar_url":"https://github.com/hugoalh-studio.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Shuffle Array (JavaScript)\n\n[**⚖️** MIT](./LICENSE.md)\n\n**🗂️**\n[![GitHub: hugoalh-studio/shuffle-array-js](https://img.shields.io/badge/hugoalh--studio/shuffle--array--js-181717?logo=github\u0026logoColor=ffffff\u0026style=flat \"GitHub: hugoalh-studio/shuffle-array-js\")](https://github.com/hugoalh-studio/shuffle-array-js)\n[![NPM: @hugoalh/shuffle-array](https://img.shields.io/badge/@hugoalh/shuffle--array-CB3837?logo=npm\u0026logoColor=ffffff\u0026style=flat \"NPM: @hugoalh/shuffle-array\")](https://www.npmjs.com/package/@hugoalh/shuffle-array)\n\n**🆙** ![Latest Release Version](https://img.shields.io/github/release/hugoalh-studio/shuffle-array-js?sort=semver\u0026color=2187C0\u0026label=\u0026style=flat \"Latest Release Version\") (![Latest Release Date](https://img.shields.io/github/release-date/hugoalh-studio/shuffle-array-js?color=2187C0\u0026label=\u0026style=flat \"Latest Release Date\"))\n\nA JavaScript module to shuffle the array's indexes.\n\n## 🎯 Target\n\n- Bun ^ v1.0.0\n- Cloudflare Workers\n- Deno \u003e= v1.34.0\n  \u003e **🛡️ Require Permission**\n  \u003e\n  \u003e *N/A*\n- NodeJS \u003e= v16.13.0\n\n### 🔗 Other Edition\n\n- [TypeScript](https://github.com/hugoalh-studio/shuffle-array-ts)\n\n## 🔰 Usage\n\n### Via Installation\n\n\u003e **🎯 Supported Target**\n\u003e\n\u003e - Cloudflare Workers\n\u003e - NodeJS\n\n1. Install via console/shell/terminal:\n    - Via NPM\n      ```sh\n      npm install @hugoalh/shuffle-array[@\u003cTag\u003e]\n      ```\n    - Via PNPM\n      ```sh\n      pnpm add @hugoalh/shuffle-array[@\u003cTag\u003e]\n      ```\n    - Via Yarn\n      ```sh\n      yarn add @hugoalh/shuffle-array[@\u003cTag\u003e]\n      ```\n2. Import at the script (`\u003cScriptName\u003e.js`):\n    ```js\n    import ... from \"@hugoalh/shuffle-array\";\n    ```\n    \u003e **ℹ️ Note**\n    \u003e\n    \u003e Although it is recommended to import the entire module, it is also able to import part of the module with sub path if available, please visit [file `package.json`](./package.json) property `exports` for available sub paths.\n\n### Via NPM Specifier\n\n\u003e **🎯 Supported Target**\n\u003e\n\u003e - Bun\n\u003e - Deno\n\n1. Import at the script (`\u003cScriptName\u003e.js`):\n    ```js\n    import ... from \"npm:@hugoalh/shuffle-array[@\u003cTag\u003e]\";\n    ```\n    \u003e **ℹ️ Note**\n    \u003e\n    \u003e Although it is recommended to import the entire module, it is also able to import part of the module with sub path if available, please visit [file `package.json`](./package.json) property `exports` for available sub paths.\n\n## 🧩 API\n\n- ```ts\n  function shuffleArray\u003cT\u003e(item: T[]): T[];\n  ```\n\n## ✍️ Example\n\n- ```js\n  const chain = [3, 7, 25, 26, 42, 62, 71, 76, 92, 93];\n\n  shuffleArray(chain);\n  //=\u003e [62, 93, 26, 42, 25, 7, 76, 71, 3, 92]\n\n  shuffleArray(chain);\n  //=\u003e [42, 3, 26, 62, 93, 7, 76, 25, 92, 71]\n  ```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhugoalh-studio%2Fshuffle-array-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhugoalh-studio%2Fshuffle-array-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhugoalh-studio%2Fshuffle-array-js/lists"}