Skip to content

arki-labs/string

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

@arki/string

String manipulation utilities — case conversion, base64 encoding, character counting, and template builders.

Installation

npm install @arki/string
# or
bun add @arki/string
# or
pnpm add @arki/string

Usage

Base64 encode / decode

import { base64 } from '@arki/string/base64';

const encoded = base64.encode('hello');
const decoded = base64.decode(encoded);

// URL-safe variant (RFC 4648)
const urlEncoded = base64.urlEncode('hello?world=1');
const urlDecoded = base64.urlDecode(urlEncoded);

Character counting

import { countCharacters } from '@arki/string/count-characters';

countCharacters('hello'); // 5
countCharacters();        // 0

Case conversion and other utilities

import { camelCase, snakeCase, pascalCase } from '@arki/string/utils';

Re-exports the case-conversion helpers from @poppinss/utils/string.

Template builder

import { StringBuilder } from '@arki/string/builder';

Re-exports the string-template builder from @poppinss/utils/string_builder.

Root entry

The root entry re-exports everything for convenience:

import { base64, countCharacters, camelCase } from '@arki/string';

Documentation

@arki/string is framework-agnostic and works on its own. When you compose it with the @arki/dot application framework, see packages/dot/docs/ for plugin authoring, lifecycle, and diagnostics.

License

MIT. See LICENSE.

About

[Read-only mirror] String manipulation utilities — case conversion, base64 encoding, character counting, and template builders.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors