-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
bd9d48e
commit cd78628
Showing
1 changed file
with
39 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,46 @@ | ||
# filipino-script-translator | ||
## filipino-script-translator | ||
|
||
Translate text into Baybayin, Buhid, or Tagbanwa scripts. | ||
Translate given text into Baybayin, Buhid, Hanunoo, or Tagbanwa scripts. | ||
|
||
## Install | ||
### Installation | ||
|
||
```bash | ||
npm install filipino-script-translator | ||
``` | ||
|
||
## Usage | ||
### Usage | ||
|
||
Import the function and the enum fom the package. | ||
You can change the `script` parameter into one of the enums, the default is `BAYBAYIN`. | ||
|
||
```ts | ||
import { Script, translate } from 'filipino-script-translator'; | ||
|
||
const result = translate('maganda', Script.BAYBAYIN); | ||
// Output: ααααα | ||
|
||
const result = translate('maganda', Script.TAGBANWA); | ||
// Output: α«α€α§ | ||
|
||
const result = translate('maganda', Script.HANUNOO); | ||
// Output: α«α€α¨α΄α§ | ||
|
||
const result = translate('maganda', Script.BUHID); | ||
// Output: ααnα | ||
``` | ||
|
||
### Testing | ||
|
||
``` | ||
npm run test | ||
``` | ||
|
||
### Linting | ||
|
||
``` | ||
npm run lint | ||
``` | ||
|
||
### License | ||
|
||
This package is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT). |