Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

change-case

Package Overview
Dependencies
Maintainers
1
Versions
45
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

change-case - npm Package Compare versions

Comparing version 0.0.4 to 0.0.5

4

index.js

@@ -27,4 +27,4 @@ var acceptString = function (fn) {

e.titleCase = e.title = acceptString(function (str, isSignificant) {
return splitWords(str).map(function (word) {
if (!isSignificant && (word.length < 3 || ~e.insignificantWords.indexOf(word))) {
return splitWords(str).map(function (word, index) {
if (index && !isSignificant && (word.length < 3 || ~e.insignificantWords.indexOf(word))) {
return word;

@@ -31,0 +31,0 @@ }

{
"name": "change-case",
"version": "0.0.4",
"version": "0.0.5",
"description": "Convert strings between camelCase, PascalCase, Title Case, snake_case, etc",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -15,2 +15,3 @@ /* global describe, it */

it('should convert to title case', function () {
assert.equal(changeCase.titleCase('a-simple-test'), 'A Simple Test');
assert.equal(changeCase.titleCase('this is a test'), 'This is a Test');

@@ -34,2 +35,3 @@ assert.equal(changeCase.titleCase('this_is_a_test'), 'This is a Test');

assert.equal(changeCase.pascalCase('Test-String'), 'TestString');
assert.equal(changeCase.pascalCase('a-test-again'), 'ATestAgain');
});

@@ -36,0 +38,0 @@

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc