{"id":23196282,"url":"https://github.com/jerridan/convert-keys-js","last_synced_at":"2026-05-05T18:35:16.635Z","repository":{"id":189428695,"uuid":"641190447","full_name":"jerridan/convert-keys-js","owner":"jerridan","description":"Convert key casing in nested JS objects and arrays","archived":false,"fork":false,"pushed_at":"2024-01-08T01:52:46.000Z","size":380,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-21T16:54:05.131Z","etag":null,"topics":["camel-case","camelcase","javascript","kebab-case","kebabcase","key-converter","snake-case","snakecase","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/jerridan.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","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":"2023-05-16T01:12:44.000Z","updated_at":"2023-12-06T03:08:24.000Z","dependencies_parsed_at":null,"dependency_job_id":"f9a770df-2c82-4240-b45a-a5945e9346fa","html_url":"https://github.com/jerridan/convert-keys-js","commit_stats":null,"previous_names":["jerridan/convert-keys-js"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/jerridan/convert-keys-js","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jerridan%2Fconvert-keys-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jerridan%2Fconvert-keys-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jerridan%2Fconvert-keys-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jerridan%2Fconvert-keys-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jerridan","download_url":"https://codeload.github.com/jerridan/convert-keys-js/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jerridan%2Fconvert-keys-js/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32663361,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-05T11:29:49.557Z","status":"ssl_error","status_checked_at":"2026-05-05T11:29:48.587Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["camel-case","camelcase","javascript","kebab-case","kebabcase","key-converter","snake-case","snakecase","typescript"],"created_at":"2024-12-18T14:17:37.314Z","updated_at":"2026-05-05T18:35:16.618Z","avatar_url":"https://github.com/jerridan.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ConvertKeys\n\n`ConvertKeys` is a tool for converting object keys between camel case, snake case and kebab case.\n\n### Key Features:\n\n- Accepts objects and arrays\n- Handles deeply-nested keys\n- Supports overrides for specific key conversions\n\n## Installation\n\nInstall `ConvertKeys` via npm or yarn:\n\n```bash\nnpm install @jerridan/convert-keys\n# or\nyarn add @jerridan/convert-keys\n```\n\n## Usage\n\nConvertKeys exports three functions:\n\n- `toSnakeCase` -\u003e for converting keys to snake case\n- `toCamelCase` -\u003e for converting keys to camel case\n- `toKebabCase` -\u003e for converting keys to kebab case\n\nEach function accepts two arguments:\n\n1. `input` -\u003e the object or array to convert\n2. `overrides` -\u003e an optional object containing overrides for specific key conversions\n\n### Examples\n\n**Converting an object**\n\n```javascript\ntoSnakeCase({ objectKey: \"value\" });\n// Output: { object_key: \"value\" }\n```\n\n**Converting a complex nested object**\n\n```javascript\ntoCamelCase({\n  object_key: [\n    [{ nested_key: 1 }, { nested_key: 2 }],\n    [{ nested_key: 3 }, { nested_key: 4 }],\n  ],\n});\n// Output:\n// {\n//   objectKey: [\n//     [{ nestedKey: 1 }, { nestedKey: 2 }],\n//     [{ nestedKey: 3 }, { nestedKey: 4 }],\n//   ],\n// }\n```\n\n**Using overrides**\n\n```javascript\nconst overrides = { nestedKey: \"overridden-key\" };\ntoKebabCase({ objectKey: { nestedKey: \"value\" } }, overrides);\n// Output:\n// { \"object-key\": { \"overridden-key\": \"value\" } }\n```\n\n## Contributing\n\nContributions to this project are welcome. Please follow these general guidelines:\n\n- **Reporting Bugs**: Submit an issue via GitHub with a clear title and description, steps to reproduce, expected behavior, and the actual behavior observed.\n- **Pull Requests**: Pull requests should be well-tested, readable, and maintain the integrity of the project. If your pull request is aimed at fixing a bug, link the relevant issue in the description. Additionally, please update the CHANGELOG.md file with a summary of your changes.\n- **Feature Requests**: Feel free to open an issue to discuss new feature ideas before starting implementation.\n\n## License\n\nThis project is released under the MIT License. For more details, see the LICENSE file in the repository.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjerridan%2Fconvert-keys-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjerridan%2Fconvert-keys-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjerridan%2Fconvert-keys-js/lists"}