Socket
Socket
Sign inDemoInstall

title-case

Package Overview
Dependencies
3
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 2.1.1 to 3.0.0

dist.es2015/index.d.ts

86

package.json
{
"name": "title-case",
"version": "2.1.1",
"description": "Title case a string",
"main": "title-case.js",
"typings": "title-case.d.ts",
"version": "3.0.0",
"description": "Transform a string into title case following English rules",
"main": "dist/index.js",
"typings": "dist/index.d.ts",
"module": "dist.es2015/index.js",
"sideEffects": false,
"jsnext:main": "dist.es2015/index.js",
"files": [
"title-case.js",
"title-case.d.ts",
"dist/",
"dist.es2015/",
"LICENSE"
],
"scripts": {
"lint": "standard",
"test-std": "mocha -- -R spec --bail",
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- -R spec --bail",
"test": "npm run lint && npm run test-cov"
"lint": "tslint \"src/**/*\" --project tsconfig.json",
"build": "rimraf dist/ dist.es2015/ && tsc && tsc -P tsconfig.es2015.json",
"specs": "jest --coverage",
"test": "npm run build && npm run lint && npm run specs && npm run size",
"size": "size-limit",
"prepare": "npm run build"
},
"repository": {
"type": "git",
"url": "git://github.com/blakeembrey/title-case.git"
"url": "git://github.com/blakeembrey/change-case.git"
},
"keywords": [
"title",
"case"
"case",
"english",
"capital",
"sentence",
"convert",
"transform"
],

@@ -33,14 +43,48 @@ "author": {

"bugs": {
"url": "https://github.com/blakeembrey/title-case/issues"
"url": "https://github.com/blakeembrey/change-case/issues"
},
"homepage": "https://github.com/blakeembrey/title-case",
"homepage": "https://github.com/blakeembrey/change-case/tree/master/packages/title-case#readme",
"size-limit": [
{
"path": "dist/index.js",
"limit": "350 B"
}
],
"jest": {
"roots": [
"<rootDir>/src/"
],
"transform": {
"\\.tsx?$": "ts-jest"
},
"testRegex": "(/__tests__/.*|\\.(test|spec))\\.(tsx?|jsx?)$",
"moduleFileExtensions": [
"ts",
"tsx",
"js",
"jsx",
"json",
"node"
]
},
"publishConfig": {
"access": "public"
},
"dependencies": {
"lower-case": "^2.0.0",
"upper-case": "^2.0.0"
},
"devDependencies": {
"istanbul": "^0.4.3",
"mocha": "^3.0.0",
"standard": "^9.0.2"
"@size-limit/preset-small-lib": "^2.2.1",
"@types/jest": "^24.0.23",
"@types/node": "^12.12.14",
"jest": "^24.9.0",
"rimraf": "^3.0.0",
"ts-jest": "^24.2.0",
"tslint": "^5.20.1",
"tslint-config-prettier": "^1.18.0",
"tslint-config-standard": "^9.0.0",
"typescript": "^3.7.2"
},
"dependencies": {
"no-case": "^2.2.0",
"upper-case": "^1.0.3"
}
"gitHead": "55911ca17c2e0c964b9b84143e14e29ffc9ff499"
}

@@ -5,9 +5,6 @@ # Title Case

[![NPM downloads][downloads-image]][downloads-url]
[![Build status][travis-image]][travis-url]
[![Test coverage][coveralls-image]][coveralls-url]
[![Bundle size][bundlephobia-image]][bundlephobia-url]
Title case a string.
> Transform a string into title case following English rules.
Supports Unicode (non-ASCII characters) and non-string entities, such as objects with a `toString` property, numbers and booleans. Empty values (`null` and `undefined`) will result in an empty string.
## Installation

@@ -21,15 +18,9 @@

```javascript
var titleCase = require('title-case');
```js
import { titleCase } from "title-case";
titleCase('string') //=> "String"
titleCase('PascalCase') //=> "Pascal Case"
titleCase('STRING', 'tr') //=> "Strıng"
titleCase("string"); //=> "String"
titleCase("follow step-by-step instructions"); //=> "Follow Step-by-Step Instructions"
```
## Typings
Includes a [TypeScript definition](title-case.d.ts).
## License

@@ -43,5 +34,3 @@

[downloads-url]: https://npmjs.org/package/title-case
[travis-image]: https://img.shields.io/travis/blakeembrey/title-case.svg?style=flat
[travis-url]: https://travis-ci.org/blakeembrey/title-case
[coveralls-image]: https://img.shields.io/coveralls/blakeembrey/title-case.svg?style=flat
[coveralls-url]: https://coveralls.io/r/blakeembrey/title-case?branch=master
[bundlephobia-image]: https://img.shields.io/bundlephobia/minzip/title-case.svg
[bundlephobia-url]: https://bundlephobia.com/result?p=title-case
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc