From 7036a56cbbaa0f00a36b31807f54378c04d06bf3 Mon Sep 17 00:00:00 2001 From: Nathachai Thongniran Date: Mon, 18 Oct 2021 13:14:33 +0700 Subject: [PATCH] docs(readme): update readme file both Thai and English versions --- README-en.md | 17 ++++++++++++++--- README.md | 17 ++++++++++++++--- 2 files changed, 28 insertions(+), 6 deletions(-) diff --git a/README-en.md b/README-en.md index b48b0bd..6ec5f07 100644 --- a/README-en.md +++ b/README-en.md @@ -12,7 +12,7 @@ Language: [ไทย](https://github.com/jojoee/bahttext/blob/master/README.md), [English](https://github.com/jojoee/bahttext/blob/master/README-en.md) -Change number to Thai pronunciation string, test against [Microsoft Office's BAHTTEXT function](https://support.office.com/en-us/article/BAHTTEXT-function-5ba4d0b4-abd3-4325-8d22-7a92d59aab9c), [Demo page](https://jojoee.github.io/bahttext/) +Change number to Thai pronunciation string, test against [Google Sheets BAHTTEXT function](https://support.google.com/docs/answer/9982303?hl=en), [Demo page](https://jojoee.github.io/bahttext/) ## Installation @@ -46,11 +46,22 @@ bahttext(63147.89) - [x] 0 Dependencies - [x] Unit test - [ ] Browser compatibility test -- [ ] Remove duplication between test code and test-case-csv file +- [x] Remove duplication between test code and test-case-csv file - [x] [Demo page](https://jojoee.github.io/bahttext/) -- [ ] Support negative number +- [x] Support negative number - [x] Fix semantic-release +## CMD + +``` +brew install curl +brew install jq +npm install -g +curl -L -o ./misc/testcases.csv https://docs.google.com/spreadsheets/d/e/2PACX-1vTb8PIKzgo07rn9UpcjqE0YrdMAmf4fyDbL2plUieLCyrn_5O3vDvece7UfkaArWQLUSsaw92jVpY_z/pub?gid=0&single=true&output=csv +csvtojson ./misc/testcases.csv | jq > ./misc/testcases.json +``` + ## Reference +- [Google Sheets BAHTTEXT function](https://support.google.com/docs/answer/9982303?hl=en) - [Microsoft Office's BAHTTEXT function](https://support.office.com/en-us/article/BAHTTEXT-function-5ba4d0b4-abd3-4325-8d22-7a92d59aab9c) - Inspired by [earthchie/BAHTTEXT.js](https://github.com/earthchie/BAHTTEXT.js) diff --git a/README.md b/README.md index 7298f65..0cae069 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ ภาษา: [ไทย](https://github.com/jojoee/bahttext/blob/master/README.md), [English](https://github.com/jojoee/bahttext/blob/master/README-en.md) -เปลี่ยนตัวเลข เป็นคำอ่านภาษาไทย, โมดูลตัวนี้ได้ทำการทดสอบกับ [Microsoft Office's BAHTTEXT function](https://support.office.com/en-us/article/BAHTTEXT-function-5ba4d0b4-abd3-4325-8d22-7a92d59aab9c), [Demo page](https://jojoee.github.io/bahttext/) เรียบร้อยแล้ว +เปลี่ยนตัวเลข เป็นคำอ่านภาษาไทย, โมดูลตัวนี้ได้ทำการทดสอบกับ [Google Sheets BAHTTEXT function](https://support.google.com/docs/answer/9982303?hl=en), [Demo page](https://jojoee.github.io/bahttext/) เรียบร้อยแล้ว ## ติดตั้ง @@ -45,11 +45,22 @@ bahttext(63147.89) - [x] 0 Dependencies - [x] ทำการทดสอบแบบ unit test - [ ] ทดสอบบนเบราว์เซอร์ ในแต่ละ เวอร์ชั่น -- [ ] ลดการซ้ำซ้อนของการเขียน ระหว่าง code และ ไฟล์ csv ในการทำการทดสอบ +- [x] ลดการซ้ำซ้อนของการเขียน ระหว่าง code และ ไฟล์ csv ในการทำการทดสอบ - [x] [หน้าตัวอย่างการใช้งาน](https://jojoee.github.io/bahttext/) -- [ ] สนับสนุนการใช้งานกับตัวเลขติดลบ +- [x] สนับสนุนการใช้งานกับตัวเลขติดลบ - [x] แก้ไข semantic-release +## CMD + +``` +brew install curl +brew install jq +npm install -g +curl -L -o ./misc/testcases.csv https://docs.google.com/spreadsheets/d/e/2PACX-1vTb8PIKzgo07rn9UpcjqE0YrdMAmf4fyDbL2plUieLCyrn_5O3vDvece7UfkaArWQLUSsaw92jVpY_z/pub?gid=0&single=true&output=csv +csvtojson ./misc/testcases.csv | jq > ./misc/testcases.json +``` + ## อ้างอิง +- [Google Sheets BAHTTEXT function](https://support.google.com/docs/answer/9982303?hl=en) - [Microsoft Office's BAHTTEXT function](https://support.office.com/en-us/article/BAHTTEXT-function-5ba4d0b4-abd3-4325-8d22-7a92d59aab9c) - แรงบัลดาลใจจาก [earthchie/BAHTTEXT.js](https://github.com/earthchie/BAHTTEXT.js)