Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

to-title-case

ianstormtaylor85.7kMIT1.0.0TypeScript support: definitely-typed

Convert a string to title case.

title, case, titlecase, string

readme

to-title-case Build Status

Convert a string to a title case. Part of the series of case helpers.

Installation

$ npm install to-title-case

Example

var toTitleCase = require('to-title-case');

toTitleCase('the catcher in the rye'); 
// "The Catcher in the Rye"

API

toTitleCase(string)

Returns the string converted to title case, preserving punctuation.

License

The MIT License (MIT)

Copyright © 2016, Ian Storm Taylor

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

changelog

1.0.0 - January 21, 2016

  • drop component support
  • cleanup readme
  • add travis ci
  • update coding style

0.1.5 - September 26, 2014

  • remove unnecessary map dependency

0.1.4 - April 1, 2014

  • upgraded map

0.1.3 - February 11, 2014

  • upgraded map

0.1.2 - October 6, 2013

  • upgraded map

0.1.1 - October 2, 2013

  • packaged for npm
  • upgraded map
  • upgraded to-capital-case

0.1.0 - September 18, 2013

  • upgraded to-capital-case
  • made uppercase after colons

0.0.1 - September 18, 2013

:sparkles: