https://github.com/ntnyq/weird-glyph
:package: Transform common glyphs to weird glyphs.
https://github.com/ntnyq/weird-glyph
weird-glyph
Last synced: 7 months ago
JSON representation
:package: Transform common glyphs to weird glyphs.
- Host: GitHub
- URL: https://github.com/ntnyq/weird-glyph
- Owner: ntnyq
- License: mit
- Created: 2025-02-20T12:03:54.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2025-02-23T12:07:56.000Z (7 months ago)
- Last Synced: 2025-03-08T23:51:44.386Z (7 months ago)
- Topics: weird-glyph
- Language: TypeScript
- Homepage:
- Size: 238 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# weird-glyph
[](https://github.com/ntnyq/weird-glyph/actions)
[](https://www.npmjs.com/package/weird-glyph)
[](https://www.npmjs.com/package/weird-glyph)
[](https://github.com/ntnyq/weird-glyph/blob/main/LICENSE)## Install
```shell
npm i weird-glyph -D
``````shell
yarn add weird-glyph -D
``````shell
pnpm add weird-glyph -D
```## Usage
```ts
// config/index.tsimport { weirdGlyph } from 'weird-glyph'
console.log(
weirdGlyph('ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789', {
category: 'script',
variant: 'regular',
}),
)
// cSpell: disable-next-line
// => ๐โฌ๐๐โฐโฑ๐ขโโ๐ฅ๐ฆโโณ๐ฉ๐ช๐ซ๐ฌโ๐ฎ๐ฏ๐ฐ๐ฑ๐ฒ๐ณ๐ด๐ต๐ถ๐ท๐ธ๐นโฏ๐ปโ๐ฝ๐พ๐ฟ๐๐๐๐โด๐ ๐๐๐๐๐๐๐๐๐๐
```## API
### weirdGlyph
- **Type**: `(input: string, options: Options) => string`
## Interface
```ts
export type Options = {
category: WeirdGlyphCategory
variant: WeirdGlyphVariant
}/**
* Weird glyph category
*/
export type WeirdGlyphCategory =
| 'circle'
| 'currency'
| 'double-struck'
| 'fancy'
| 'fraktur'
| 'latin'
| 'monospace'
| 'sans-serif'
| 'script'
| 'serif'
| 'square'/**
* Weird glyph variant
*/
export type WeirdGlyphVariant =
| 'arrow'
| 'black'
| 'bold-italic'
| 'bold'
| 'cross'
| 'dot'
| 'extended'
| 'fireworks'
| 'happy'
| 'italic'
| 'line'
| 'regular'
| 'sad'
| 'slash'
| 'smallcaps'
| 'tildestrikethrough'
| 'upside'
| 'winding'
| 'xabove'
```## License
[MIT](./LICENSE) License ยฉ 2025-PRESENT [ntnyq](https://github.com/ntnyq)