just a JPTableFull.pdf parser
npm install jyutping-table-parser
const jyutpingTableParser = require('jyutping-table-parser');
const characters = jyutpingTableParser.parseJyutpingInput();
Output (characters) should be
[
{
type: TYPE,
rg: RG,
rad: RAD,
ucs2: UCS2,
ch: CH,
infoArray: [
{
jyutping: JYUTPING,
en: EN,
pn: PN,
cl: CL,
sc: SC,
ref: [
{
ucs2: UCS2,
ch: CH,
},
...
]
},
...
]
},
...
]
-
(Optional) Array of string with possible values
'<', '#', '>', 'S', '$', '*', '**', '***', '****'
- Number with possible values 1, 2 or 3.
- (Optional) Boolean, true if the character is radical
- String. Range between '3400' - 'F7EE'
- String. Unicode re-mapped to HKSCS_2016 one.
- (Optional) Array of String each contains a jyutping value.
- (Optional) String with possible values 's', 't'
- Number starts with 1.
- (Optional) Boolean.
- (Optional) String with value '1.x' or '2'
For more detailed value description, please reference the original PDF section 5.
{
"type": [
">"
],
"rg": 1,
"ucs2": "9673",
"ch": "陳",
"infoArray": [
{
"jyutping": [
"can4"
],
"en": "t",
"pn": 1
},
{
"jyutping": [
"can2"
],
"en": "t",
"pn": 2,
"cl": true,
"sc": "2"
},
{
"jyutping": [
"zan6"
],
"en": "t",
"pn": 3
}
]
}
npm test
or yarn test
In lieu of a formal style guide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code.