{"_id":"@amitchandmandal/array-utils","_rev":"2-a2cae705f491f83ffdbf055aceaef5bb","name":"@amitchandmandal/array-utils","dist-tags":{"latest":"1.0.1"},"versions":{"1.0.0":{"name":"@amitchandmandal/array-utils","version":"1.0.0","license":"MIT","_id":"@amitchandmandal/array-utils@1.0.0","maintainers":[{"name":"amitchandmandal","email":"amyt143man@gmail.com"}],"dist":{"shasum":"6ed1a6152d3489eb80e4031aa45d721dbcc6653d","tarball":"https://registry.npmjs.org/@amitchandmandal/array-utils/-/array-utils-1.0.0.tgz","fileCount":13,"integrity":"sha512-w9gcrCco6wkF6op0qegvw4j4DBqoHhJuqoCCqfUyCLr49Yr5H5SLvg+VmNf43YADnDdduXC2jN85eePBeKEM6g==","signatures":[{"sig":"MEQCIG/AfBRwW5M6Y6DlJrr+N6GrDZ1K0R9z7rcCTGiE9/ssAiAf1N55nXXgpWf6/ea4sQlxj0n8icEbRkKkyGqh64XVcQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":3177},"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"test":"vitest","build":"tsc","prepublishOnly":"npm run build"},"_npmUser":{"name":"amitchandmandal","email":"amyt143man@gmail.com"},"_npmVersion":"10.9.2","description":"Lightweight, type-safe array utility functions","directories":{},"_nodeVersion":"22.15.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.3"},"_npmOperationalInternal":{"tmp":"tmp/array-utils_1.0.0_1767630956961_0.976089804596634","host":"s3://npm-registry-packages-npm-production"}},"1.0.1":{"name":"@amitchandmandal/array-utils","version":"1.0.1","publishConfig":{"access":"public"},"description":"Lightweight, type-safe array utility functions","main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"tsc","test":"vitest","prepublishOnly":"npm run build"},"license":"MIT","devDependencies":{"typescript":"^5.9.3"},"_id":"@amitchandmandal/array-utils@1.0.1","_nodeVersion":"22.15.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-WpqKsgB2h88CDIgpRjjgMq5P8tR+ErwKxh1DB0alQwPNZNApQV7Ws3Wcx705KSAeHM9ky4PbtMBpd1ZKlRiX6Q==","shasum":"242071dda28853915fd906b6ea6318805f2a96a1","tarball":"https://registry.npmjs.org/@amitchandmandal/array-utils/-/array-utils-1.0.1.tgz","fileCount":15,"unpackedSize":6663,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIEx+94l7dzefYzy7I6fGMWBEUU87KnKVX6/WTumM/vPaAiACqXvk8i24fGsRCnALhZv7uKzCI3cBAAGbfSOuvzyykw=="}]},"_npmUser":{"name":"amitchandmandal","email":"amyt143man@gmail.com"},"directories":{},"maintainers":[{"name":"amitchandmandal","email":"amyt143man@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/array-utils_1.0.1_1767632931558_0.03801570624608641"},"_hasShrinkwrap":false}},"time":{"created":"2026-01-05T16:35:56.853Z","modified":"2026-01-05T17:08:51.927Z","1.0.0":"2026-01-05T16:35:57.114Z","1.0.1":"2026-01-05T17:08:51.712Z"},"license":"MIT","description":"Lightweight, type-safe array utility functions","maintainers":[{"name":"amitchandmandal","email":"amyt143man@gmail.com"}],"readme":"You can copy the **entire block below** exactly as it is and save it in your package folder as `README.md`. This is a fully formatted, ready-to-use README for your `@amitchandmandal/array-utils` package:\r\n\r\n````md\r\n# Array Utils\r\n\r\nA small, lightweight utility library for working with arrays in JavaScript and TypeScript.  \r\nProvides helpful functions like removing duplicates, finding the largest/smallest element, and more.\r\n\r\n---\r\n\r\n## Installation\r\n\r\nInstall via npm:\r\n\r\n```bash\r\nnpm install @amitchandmandal/array-utils\r\n````\r\n\r\nOr with yarn:\r\n\r\n```bash\r\nyarn add @amitchandmandal/array-utils\r\n```\r\n\r\n---\r\n\r\n## Usage\r\n\r\n### Importing\r\n\r\n```ts\r\n// ES Modules\r\nimport { uniqueNumbers, getLargest, getSmallest } from '@amitchandmandal/array-utils';\r\n\r\n// CommonJS\r\nconst { uniqueNumbers, getLargest, getSmallest } = require('@amitchandmandal/array-utils');\r\n```\r\n\r\n### Examples\r\n\r\n#### Remove duplicates from an array\r\n\r\n```ts\r\nconst numbers = [1, 2, 2, 3, 3, 4];\r\nconst unique = uniqueNumbers(numbers);\r\n\r\nconsole.log(unique); // [1, 2, 3, 4]\r\n```\r\n\r\n#### Find the largest number in an array\r\n\r\n```ts\r\nconst numbers = [1, 5, 2, 9, 3];\r\nconst largest = getLargest(numbers);\r\n\r\nconsole.log(largest); // 9\r\n```\r\n\r\n#### Find the smallest number in an array\r\n\r\n```ts\r\nconst numbers = [1, 5, 2, 9, 3];\r\nconst smallest = getSmallest(numbers);\r\n\r\nconsole.log(smallest); // 1\r\n```\r\n\r\n---\r\n\r\n## API\r\n\r\n| Function        | Description                              | Parameters        | Returns  |\r\n| --------------- | ---------------------------------------- | ----------------- | -------- |\r\n| `uniqueNumbers` | Removes duplicates from an array         | `array: T[]`      | `T[]`    |\r\n| `getLargest`    | Returns the largest element in an array  | `array: number[]` | `number` |\r\n| `getSmallest`   | Returns the smallest element in an array | `array: number[]` | `number` |\r\n\r\n---\r\n\r\n## TypeScript Support\r\n\r\nThis package includes TypeScript types. You can import it directly in TypeScript projects:\r\n\r\n```ts\r\nimport { uniqueNumbers } from '@amitchandmandal/array-utils';\r\n```\r\n\r\n---\r\n\r\n## Contributing\r\n\r\nContributions, suggestions, and bug reports are welcome! Feel free to open an issue or a pull request.\r\n\r\nWhen contributing, please make sure to:\r\n\r\n* Follow consistent coding style\r\n* Add tests for new functionality\r\n* Update documentation if needed\r\n\r\n\r\n","readmeFilename":"README.md"}