ProvenPin Install

change-case convert string cases: working versions (tested 2026-10-15)

Convert identifiers between camel, snake, kebab and Pascal case with the change-case package.

passed2 passed · 0 failed2026-10-15 20:56 UTC
Status
passed
Last passed
2026-10-15 20:56 UTC
Tests
2 / 2
Language
TypeScript
Runtime
node v22.23.3
pinned versions3
change-case@5.4.4@types/node@26.6.5tsx@4.23.15
run it
npm install --no-audit --no-fund --ignore-scripts=false
npm test
test environment
node v22.23.3
linux 6.17.0-1022-azure
x64
runner: github-actions 38805962781

The code

Exactly the files that passed. Your agent can pull them with get_recipe("change-case-string-cases") (install), or see them on GitHub.

package.json
{
  "name": "change-case-string-cases",
  "private": true,
  "type": "module",
  "scripts": {
    "test": "node --import tsx --test test/*.test.ts"
  },
  "dependencies": {
    "change-case": "5.4.4"
  },
  "devDependencies": {
    "@types/node": "26.6.5",
    "tsx": "4.23.15"
  }
}
src/cases.ts
import { camelCase, snakeCase, kebabCase, pascalCase, capitalCase } from "change-case";

export function allCases(input: string) {
  return {
    camel: camelCase(input),
    snake: snakeCase(input),
    kebab: kebabCase(input),
    pascal: pascalCase(input),
    capital: capitalCase(input),
  };
}
test/cases.test.ts
import { test } from "node:test";
import assert from "node:assert/strict";
import { allCases } from "../src/cases.ts";

test("converts mixed identifiers", () => {
  assert.deepEqual(allCases("hello_world-test"), {
    camel: "helloWorldTest",
    snake: "hello_world_test",
    kebab: "hello-world-test",
    pascal: "HelloWorldTest",
    capital: "Hello World Test",
  });
});

test("handles already camel input", () => {
  const out = allCases("orderId");
  assert.equal(out.snake, "order_id");
  assert.equal(out.kebab, "order-id");
});

Connect to ProvenPin

Add the free MCP server so your agent can pull this recipe and others like it. Same setup as the docs.

terminal
claude mcp add --transport http provenpin https://mcp.provenpin.com/mcp

Any other MCP client: Streamable HTTP at https://mcp.provenpin.com/mcp. No API key, no signup.