npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

@tpmjs/text-transformer

v1.0.22

Published

Una herramienta de transformación de texto para TPMJS - convierte mayúsculas/minúsculas, crea slugs, y más

Readme

Text Transformer Tool for TPMJS

A text transformation utility tool for the TPMJS ecosystem. Convert text case, generate slugs, and perform various text operations optimized for AI and LLM consumption.

Installation

npm install @tpmjs/text-transformer

Usage

As a Library

import { transform } from '@tpmjs/text-transformer';

// Transform to uppercase
const result = transform({ operation: 'uppercase', text: 'hello world' });
// Result: "HELLO WORLD"

// Generate a URL slug
const slug = transform({ operation: 'slug', text: 'My Blog Post Title!' });
// Result: "my-blog-post-title"

// Convert to camelCase
const camel = transform({ operation: 'camelcase', text: 'hello world example' });
// Result: "helloWorldExample"

As a CLI Tool

# Install globally
npm install -g @tpmjs/text-transformer

# Use the CLI
text-transform uppercase "hello world"
# Output: HELLO WORLD

text-transform slug "My Blog Post Title"
# Output: my-blog-post-title

text-transform camelcase "user first name"
# Output: userFirstName

Available Operations

| Operation | Description | Example Input | Example Output | |-----------|-------------|---------------|----------------| | uppercase | Convert to UPPERCASE | "hello world" | "HELLO WORLD" | | lowercase | Convert to lowercase | "HELLO WORLD" | "hello world" | | titlecase | Convert To Title Case | "hello world" | "Hello World" | | camelcase | convertToCamelCase | "hello world" | "helloWorld" | | pascalcase | ConvertToPascalCase | "hello world" | "HelloWorld" | | snakecase | convert_to_snake_case | "hello world" | "hello_world" | | kebabcase | convert-to-kebab-case | "hello world" | "hello-world" | | slug | convert-to-url-slug | "My Post!" | "my-post" | | trim | Remove extra whitespace | " hello world " | "hello world" | | reverse | Reverse text | "hello" | "olleh" |

API Reference

transform(options: TextTransformOptions): string

Main transformation function.

Parameters:

  • options.operation: The transformation operation to perform
  • options.text: The text to transform

Returns: Transformed text string

Individual Functions

You can also import and use individual transformation functions:

import {
  toUpperCase,
  toLowerCase,
  toSlug,
  toCamelCase
} from '@tpmjs/text-transformer';

const upper = toUpperCase('hello');
const slug = toSlug('My Blog Post');

TPMJS Metadata

This package is designed for the TPMJS ecosystem with the following capabilities:

  • Transform text case (uppercase, lowercase, title case, camel case, pascal case, snake case, kebab case)
  • Generate URL-friendly slugs
  • Remove extra whitespace
  • Reverse text

License

MIT

Contributing

This is a tool package for TPMJS. Contributions are welcome!

TPMJS

TPMJS is "The Tool Package Manager for the AI Era" - a centralized registry for tools, skills, and agent capabilities optimized for LLM consumption.

Learn more at: https://github.com/tpmjs