@unknownflo/string-toolkit
v1.1.0
Published
A lightweight JavaScript library for string manipulation.
Maintainers
Readme
@unknownflo/string-toolkit
A lightweight and efficient JavaScript library for string manipulation. This toolkit provides simple and reliable functions to convert strings into different formats such as snake_case and kebab-case.
Description
The @unknownflo/string-toolkit is a minimal, dependency-free utility library for common string transformations. It helps format strings for identifiers, filenames, URLs and general text processing.
Features
- Convert strings to snake_case
- Convert strings to kebab-case
- Lightweight and dependency-free
- Tested with Jest
- Easy to use in Node.js and JavaScript projects
Installation
npm
npm install @unknownflo/string-toolkitUsage
CommonJS
const { toSnakeCase, toKebabCase } = require("@unknownflo/string-toolkit");
console.log(toSnakeCase("Hello World"));
// hello_world
console.log(toKebabCase("Hello World"));
// hello-worldCommonJS
import { toSnakeCase, toKebabCase } from "@unknownflo/string-toolkit";
console.log(toSnakeCase("Hello World"));
// hello_world
console.log(toKebabCase("Hello World"));
// hello-worldContributing
- Fork the repository
- Create a feature branch
- Commit your changes
- Open a pull request
- Security
Report security issues in SECURITY.md.
License
MIT License
npm
https://www.npmjs.com/package/@unknownflo/string-toolkit
Author
UnknownFlo: GitHub: https://github.com/unknownflo
Lilberto: GitHub: https://github.com/Lilberto
