Skip to content

Commit

Permalink
Update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
ayaka14732 committed Mar 24, 2021
1 parent 744a232 commit f3851be
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 9 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/.vscode
/.mypy_cache
__pycache__

/*/**/LICENSE
/*/**/README.md
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ npm install yitizi
### JavaScript (browser)

```html
<script src="https://cdn.jsdelivr.net/npm/[email protected].0"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected].1"></script>
```

```javascript
Expand Down
15 changes: 10 additions & 5 deletions build/javascript.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,16 @@
#!/bin/bash
echo "
const Yitizi = {
yitiziData: `cat yitizi.json`,
get: function get(c) {
yitiziData: `cat yitizi.json`,
get:
/**
* Get all the variant characters of a given character.
* @param {string} c A Chinese character.
* @returns {string[]} All the variant characters of the given character.
*/
function get(c) {
const res = this.yitiziData[c];
return res == null ? [] : [...res];
}
}
};
try { module.exports = exports = Yitizi; } catch (e) {}
" > javascript/index.js
try { module.exports = exports = Yitizi; } catch (e) {}" > javascript/index.js
2 changes: 1 addition & 1 deletion javascript/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "yitizi",
"version": "0.1.0",
"version": "0.1.1",
"description": "Input a Chinese character. Output all the variant characters of it.",
"main": "index.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion python/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

setup(
name='yitizi',
version='0.1.0',
version='0.1.1',
description='Input a Chinese character. Output all the variant characters of it.',
long_description=long_description,
long_description_content_type='text/markdown',
Expand Down
2 changes: 1 addition & 1 deletion python/src/yitizi/yitizi.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

def get(c):
'''
Input a Chinese character. Output all the variant characters of it.
Get all the variant characters of a given character.
```
>>> import yitizi
Expand Down

0 comments on commit f3851be

Please sign in to comment.