{"id":15650226,"url":"https://github.com/jonschlinkert/pascalcase","last_synced_at":"2025-07-04T18:08:38.923Z","repository":{"id":36708143,"uuid":"41014690","full_name":"jonschlinkert/pascalcase","owner":"jonschlinkert","description":"Convert a string to pascal case (upper camel case). Used by more than 8.7 million projects on GitHub! Please follow this library's author: https://github.com/jonschlinkert","archived":false,"fork":false,"pushed_at":"2021-12-29T15:12:27.000Z","size":18,"stargazers_count":37,"open_issues_count":2,"forks_count":5,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-06-16T03:12:46.822Z","etag":null,"topics":["camel","camel-case","camelcase","case","casing","casing-change","change-case","javascript","jonschlinkert","nodejs","pascal-case","pascalcase","string","upper-camel-case"],"latest_commit_sha":null,"homepage":"","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/jonschlinkert.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":"2015-08-19T05:13:50.000Z","updated_at":"2025-02-14T08:03:25.000Z","dependencies_parsed_at":"2022-08-25T20:00:36.142Z","dependency_job_id":null,"html_url":"https://github.com/jonschlinkert/pascalcase","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/jonschlinkert/pascalcase","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jonschlinkert%2Fpascalcase","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jonschlinkert%2Fpascalcase/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jonschlinkert%2Fpascalcase/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jonschlinkert%2Fpascalcase/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jonschlinkert","download_url":"https://codeload.github.com/jonschlinkert/pascalcase/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jonschlinkert%2Fpascalcase/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260204340,"owners_count":22974111,"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":["camel","camel-case","camelcase","case","casing","casing-change","change-case","javascript","jonschlinkert","nodejs","pascal-case","pascalcase","string","upper-camel-case"],"created_at":"2024-10-03T12:34:06.263Z","updated_at":"2025-06-20T21:36:06.013Z","avatar_url":"https://github.com/jonschlinkert.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# pascalcase [![NPM version](https://img.shields.io/npm/v/pascalcase.svg?style=flat)](https://www.npmjs.com/package/pascalcase) [![NPM monthly downloads](https://img.shields.io/npm/dm/pascalcase.svg?style=flat)](https://npmjs.org/package/pascalcase) [![NPM total downloads](https://img.shields.io/npm/dt/pascalcase.svg?style=flat)](https://npmjs.org/package/pascalcase)  [![Tests](https://github.com/jonschlinkert/pascalcase/actions/workflows/main.yml/badge.svg)](https://github.com/jonschlinkert/pascalcase/actions/workflows/main.yml)\n\n\u003e Convert a string to pascal case (upper camelcase).\n\nPlease consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support.\n\n## Install\n\nInstall with [npm](https://www.npmjs.com/) (requires [Node.js](https://nodejs.org/en/) \u003e=14):\n\n```sh\n$ npm install --save pascalcase\n```\n\n## Prerequisites\n\nRequires [Node.js](https://nodejs.org/en/) version \u003e= 14.\n\n## Usage\n\n```js\nimport pascalcase from 'pascalcase';\n// or the following if you prefer\nimport { pascalcase } from 'pascalcase';\n\nconsole.log(pascalcase('a')); //=\u003e 'A'\nconsole.log(pascalcase('foo bar baz')); //=\u003e 'FooBarBaz'\nconsole.log(pascalcase('  foo bar baz  ')); //=\u003e 'FooBarBaz'\nconsole.log(pascalcase('foo_bar-baz')); //=\u003e 'FooBarBaz'\nconsole.log(pascalcase('foo.bar.baz')); //=\u003e 'FooBarBaz'\nconsole.log(pascalcase('foo/bar/baz')); //=\u003e 'FooBarBaz'\nconsole.log(pascalcase('foo[bar)baz')); //=\u003e 'FooBarBaz'\nconsole.log(pascalcase('#foo+bar*baz')); //=\u003e 'FooBarBaz'\nconsole.log(pascalcase('$foo~bar`baz')); //=\u003e 'FooBarBaz'\nconsole.log(pascalcase('_foo_bar-baz-')); //=\u003e 'FooBarBaz'\nconsole.log(pascalcase('foo 2 bar 5 baz')); //=\u003e 'Foo2Bar5Baz'\nconsole.log(pascalcase('foo2bar5baz')); //=\u003e 'Foo2bar5baz'\n```\n\n## Uppercase character sequences\n\nIf you wish to preserve upper case character sequences, you may pass an options object with the `preserveConsecutiveUppercase` option set to `true`:\n\n```js\nconsole.log(pascalcase('The IRS Is Mean')); //=\u003e 'TheIrsIsMean\nconsole.log(pascalcase('The IRS Is Mean', { preserveConsecutiveUppercase: true })); //=\u003e TheIRSIsMean\n\nconsole.log(pascalcase('We saw a UFO')); //=\u003e WeSawAUfo\nconsole.log(pascalcase('We saw a UFO', { preserveConsecutiveUppercase: true })); //=\u003e WeSawAUFO\n```\n\n## Options\n\nAll options are passed to [sindresorhus/camelcase](https://github.com/sindresorhus/camelcase), please visit that project to learn about all available options.\n\n## About\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cstrong\u003eContributing\u003c/strong\u003e\u003c/summary\u003e\n\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).\n\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cstrong\u003eRunning Tests\u003c/strong\u003e\u003c/summary\u003e\n\nRunning and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:\n\n```sh\n$ npm install \u0026\u0026 npm test\n```\n\n\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003e\u003cstrong\u003eBuilding docs\u003c/strong\u003e\u003c/summary\u003e\n\n_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_\n\nTo generate the readme, run the following command:\n\n```sh\n$ npm install -g verbose/verb#dev verb-generate-readme \u0026\u0026 verb\n```\n\n\u003c/details\u003e\n\n### Related projects\n\nYou might also be interested in these projects:\n\n* [ansi-colors](https://www.npmjs.com/package/ansi-colors): Easily add ANSI colors to your text and symbols in the terminal. A faster drop-in… [more](https://github.com/doowb/ansi-colors) | [homepage](https://github.com/doowb/ansi-colors \"Easily add ANSI colors to your text and symbols in the terminal. A faster drop-in replacement for chalk, kleur and turbocolor (without the dependencies and rendering bugs).\")\n* [justified](https://www.npmjs.com/package/justified): Wraps words to a specified length and justifies the text in each line. | [homepage](https://github.com/jonschlinkert/justified \"Wraps words to a specified length and justifies the text in each line.\")\n* [randomatic](https://www.npmjs.com/package/randomatic): Generate randomized strings of a specified length using simple character sequences. The original generate-password. | [homepage](https://github.com/jonschlinkert/randomatic \"Generate randomized strings of a specified length using simple character sequences. The original generate-password.\")\n* [word-wrap](https://www.npmjs.com/package/word-wrap): Wrap words to a specified length. | [homepage](https://github.com/jonschlinkert/word-wrap \"Wrap words to a specified length.\")\n\n### Author\n\n**Jon Schlinkert**\n\n* [GitHub Profile](https://github.com/jonschlinkert)\n* [Twitter Profile](https://twitter.com/jonschlinkert)\n* [LinkedIn Profile](https://linkedin.com/in/jonschlinkert)\n\n### License\n\nCopyright © 2021, [Jon Schlinkert](https://github.com/jonschlinkert).\nReleased under the [MIT License](LICENSE).\n\n***\n\n_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.8.0, on December 29, 2021._","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjonschlinkert%2Fpascalcase","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjonschlinkert%2Fpascalcase","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjonschlinkert%2Fpascalcase/lists"}