{"id":28236965,"url":"https://github.com/bytebodger/capitalize","last_synced_at":"2025-06-10T15:30:59.139Z","repository":{"id":57167207,"uuid":"354156503","full_name":"bytebodger/capitalize","owner":"bytebodger","description":"A JavaScript utility for capitalizing strings","archived":false,"fork":false,"pushed_at":"2021-04-03T00:14:03.000Z","size":81,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-19T00:17:28.803Z","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/bytebodger.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":null,"support":null}},"created_at":"2021-04-02T23:28:46.000Z","updated_at":"2021-05-02T19:32:36.000Z","dependencies_parsed_at":"2022-08-30T15:21:55.607Z","dependency_job_id":null,"html_url":"https://github.com/bytebodger/capitalize","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bytebodger%2Fcapitalize","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bytebodger%2Fcapitalize/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bytebodger%2Fcapitalize/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bytebodger%2Fcapitalize/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bytebodger","download_url":"https://codeload.github.com/bytebodger/capitalize/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bytebodger%2Fcapitalize/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259101154,"owners_count":22805217,"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":"2025-05-19T00:17:10.938Z","updated_at":"2025-06-10T15:30:59.131Z","avatar_url":"https://github.com/bytebodger.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# capitalize\n\n`capitalize` is a JavaScript utility for capitalizing strings.\n\n## Usage\n\nAfter installation, import the package:\n\n```javascript\nimport { capitalize } from '@toolz/capitalize';\n```\n\n### .firstLetter()\n\nCapitalizes the first letter - and only the first letter - in the string.\n\n```javascript\nconst API = {\n   arguments: {\n      string: {\n         required,\n         format: 'non-empty string',\n      },\n   },\n   returns: string,\n}\n```\n\n**Examples**\n\n```javascript\nconst florida = 'florida';\nconst country = 'united states of america';\nconsole.log(capitalize.firstLetter(florida)); // Florida\nconsole.log(capitalize.firstLetter(country)); // United states of america\n```\n\n### .everyFirstLetter()\n\nSplits the string by spaces (`' '`), treating each resulting value as a \"word\". It then capitalizes the first letter in each word.\n\n```javascript\nconst API = {\n   arguments: {\n      string: {\n         required,\n         format: 'non-empty string',\n      },\n   },\n   returns: string,\n}\n```\n\n**Examples**\n\n```javascript\nconst florida = 'florida';\nconst country = 'united states of america';\nconsole.log(capitalize.everyFirstLetter(florida)); // Florida\nconsole.log(capitalize.everyFirstLetter(country)); // United States Of America\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbytebodger%2Fcapitalize","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbytebodger%2Fcapitalize","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbytebodger%2Fcapitalize/lists"}