Skip to content

Commit 333e21e

Browse files
authored
Merge pull request #76 from mcnaveen/refactor/general
refactor(general): add random-array-item package and few improvements
2 parents 92d134f + 3eacfba commit 333e21e

File tree

6 files changed

+552
-17
lines changed

6 files changed

+552
-17
lines changed

.all-contributorsrc

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,20 @@
55
"imageSize": 100,
66
"commit": false,
77
"contributors": [
8+
{
9+
"login": "mcnaveen",
10+
"name": "MC Naveen",
11+
"avatar_url": "https://avatars.githubusercontent.com/u/8493007?v=4",
12+
"profile": "https://github.com/mcnaveen",
13+
"contributions": [
14+
"code",
15+
"data",
16+
"doc",
17+
"ideas",
18+
"maintenance",
19+
"review"
20+
]
21+
},
822
{
923
"login": "jonah-butler",
1024
"name": "jonah-butler",
@@ -35,4 +49,4 @@
3549
"repoType": "github",
3650
"repoHost": "https://github.com",
3751
"skipCi": true
38-
}
52+
}

README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,21 @@ OR
9999
- Go Live
100100
```
101101

102+
## ✍️ Commit
103+
104+
- Stage all changes
105+
```
106+
git add .
107+
```
108+
- Commit the changes
109+
```
110+
yarn commit
111+
```
112+
- Push the changes to GitHub
113+
```
114+
git push <TO YOUR FORK>
115+
```
116+
102117
## ⚛ CREDITS
103118

104119
- Thanks to [Santhosh Veer](https://github.com/mskian) for Progressive Web APP - [Source Code](https://github.com/mskian/vue-random-words)

package.json

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,15 @@
99
"cheerio": "^1.0.0-rc.12",
1010
"express": "^4.18.1",
1111
"node-pronounce": "^0.0.4",
12+
"random-array-item": "^0.0.2",
1213
"random-useragent": "^0.5.0"
1314
},
1415
"scripts": {
1516
"test": "echo \"Error: no test specified\" && exit 1",
1617
"start": "node index.js",
1718
"action": "node test.js",
18-
"dev": "nodemon index.js --ext '*'"
19+
"dev": "nodemon index.js --ext '*'",
20+
"commit": "gacp"
1921
},
2022
"type": "module",
2123
"keywords": [
@@ -35,6 +37,13 @@
3537
"author": "MC Naveen",
3638
"license": "MIT",
3739
"devDependencies": {
40+
"gacp": "^3.0.2",
3841
"nodemon": "^2.0.18"
42+
},
43+
"gacp": {
44+
"add": false,
45+
"push": false,
46+
"emoji": "emoji",
47+
"editor": false
3948
}
40-
}
49+
}

routes/dutch.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import express from "express";
22
const router = express.Router();
33
import { pronounce } from "node-pronounce";
44
import { readFileSync } from "fs";
5-
import { randomArrayItem } from "../utils/randomArrayItem.js";
5+
import { randomArrayItem } from "random-array-item";
66
var dutchRandomWord = [];
77
const dutchWordsData = JSON.parse(readFileSync(new URL("../data/dutch/words.json", import.meta.url)));
88

utils/randomArrayItem.js

Lines changed: 0 additions & 6 deletions
This file was deleted.

0 commit comments

Comments
 (0)