Skip to content

Commit

Permalink
eastern-arabic/version/0.0.1-next.0
Browse files Browse the repository at this point in the history
  • Loading branch information
amerharb committed Mar 11, 2024
1 parent 9f53606 commit 376313e
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 1 deletion.
2 changes: 1 addition & 1 deletion packages/eastern-arabic/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@numerals/eastern-arabic",
"version": "0.0.1",
"version": "0.0.1-next.0",
"main": "dist/src/index.js",
"types": "dist/src/index.d.ts",
"files": [
Expand Down
17 changes: 17 additions & 0 deletions packages/numerals-client/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"name": "numerals-client",
"private": true,
"version": "0.0.1",
"main": "dist/index.js",
"scripts": {
"build": "rm -rf dist && tsc",
"start": "node dist/index.js",
"test": "echo \"Error: no test specified\" && exit 0",
"dev": "npx ts-node src/index.ts",
"lint": "npx eslint . --max-warnings 0",
"lint:fix": "npx eslint . --fix"
},
"dependencies": {
"@numerals/eastern-arabic": "workspace:^"
}
}
21 changes: 21 additions & 0 deletions packages/numerals-client/src/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import { convert } from '@numerals/eastern-arabic'

log('@numerals/eastern-arabic')

log(calmConvert(123))
log(calmConvert(123.456))

log('Done')

function calmConvert(source: number): string {
try {
return convert(source)
} catch (e: any) {
return e.message
}
}

function log(message: string): void {
// eslint-disable-next-line no-console
console.log(message)
}
6 changes: 6 additions & 0 deletions packages/numerals-client/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"outDir": "dist",
}
}

0 comments on commit 376313e

Please sign in to comment.