1.0.1 • Published 5 years ago

alphabet-to-phonetic v1.0.1

Weekly downloads
3
License
ISC
Repository
github
Last release
5 years ago

Alphabet to Phonetic

Convert alphabetical text to phonetical form. Read here for more information.

Why?

First of all, yes, I'm totally aware of how trivial this package is. Also I know that there's so many useless npm packages right now that nobody even care anymore. The sole purpose of this package is for me to learn about npm publishing so that in the near future I'll have the general idea on how to publish a npm package.

What is Phonetic?

Phonetic alphabet is a widely known alphabet that's used in voice communication. This package use NATO phonetic alphabet on its implementation.

LetterPhonetic Letter
aalpha
bbravo
ccharlie
ddelta
eecho
ffoxtrot
ggolf
hhotel
iindia
jjuliet
kkilo
llima
mmike
nnovember
ooscar
ppapa
qquebec
rromeo
ssierra
ttango
uuniform
vvictor
wwhiskey
xx-ray
yyankee
zzulu

Usage

Install this package using your favourit package manager.

npm

npm install alphabet-to-phonetic

yarn

yarn add alphabet-to-phonetic

Add it to your code.

// es
import atp from 'alphabet-to-phonetic';

// typescript
import * as atp from 'alphabet-to-phonetic';

// commonJs
const atp = require('alphabet-to-phonetic');

Use it.

console.log(atp.convert('lorem ipsum'));
// expected 'lima oscar romeo echo mike  india papa sierra uniform mike'

Available Methods

Convert

Convert alphabet to phonetical form.

atp.convert(text: string): string

Reverse

Convert phonetical to alphabet form.

atp.reverse(text: string): string

Matias (2018)

1.0.1

5 years ago

1.0.0

5 years ago