4343 - [ Trending Repositories] ( #trending-repositories )
4444 - [ Trending Developers] ( #trending-developers )
4545 - [ List Languages] ( #list-languages )
46+ - [ List Spoken Languages] ( #list-spoken-languages )
4647- [ NPM Package] ( #npm-package )
4748 - [ Install] ( #install )
4849 - [ Usage] ( #usage )
4950 - [ API] ( #api )
5051 - [ languages] ( #languages )
52+ - [ spokenLanguages] ( #spokenlanguages )
5153 - [ fetchRepositories(params)] ( #fetchrepositoriesparams )
5254 - [ fetchDevelopers(params)] ( #fetchdevelopersparams )
5355- [ Contributors] ( #contributors )
7678- ** [ GitNews] ( https://git.news ) ** : Trending repositories from GitHub, HackerNews & Reddit (Mobile & Desktop).
7779- ** [ mini-github] ( https://github.com/kezhenxu94/mini-github ) ** : GitHub WeChat Mini Program (可能是全网功能最全的 GitHub 微信小程序).
7880- ** [ StarGit] ( https://github.com/theArgex/stargit2.0 ) ** ([ Website] ( https://stargit.xyz ) ): Find trending repositories from GitHub. Built with Angular.
81+ - ** [ GitTouch] ( https://github.com/pd4d10/git-touch ) ** ([ App Store] ( https://itunes.apple.com/us/app/gittouch/id1452042346 ) , [ Google Play] ( https://play.google.com/store/apps/details?id=io.github.pd4d10.gittouch ) ): Open source GitHub App built with Flutter.
7982
8083## Backers
8184
@@ -109,6 +112,7 @@ https://github-trending-api.now.sh/repositories?language=javascript&since=weekly
109112
110113- ` language ` : ** optional** , list trending repositories of certain programming languages, possible values are listed [ here] ( ./src/languages.json ) .
111114- ` since ` : ** optional** , default to ` daily ` , possible values: ` daily ` , ` weekly ` and ` monthly ` .
115+ - ` spoken_language_code ` : ** optional** , list trending repositories of certain spoken languages (e.g English, Chinese), possible values are listed [ here] ( ./src/spoken-languages.json ) .
112116
113117** Response:**
114118
@@ -176,8 +180,6 @@ https://github-trending-api.now.sh/developers?language=javascript&since=weekly
176180
177181### List Languages
178182
179- Receive popular languages and all languages.
180-
181183** URL Endpoint:**
182184
183185https://github-trending-api.now.sh/languages
@@ -187,24 +189,53 @@ https://github-trending-api.now.sh/languages
187189``` json
188190[
189191 {
190- "id " : " 1c-enterprise" ,
192+ "urlParam " : " 1c-enterprise" ,
191193 "name" : " 1C Enterprise"
192194 },
193195 {
194- "id " : " abap" ,
196+ "urlParam " : " abap" ,
195197 "name" : " ABAP"
196198 },
197199 {
198- "id " : " abnf" ,
200+ "urlParam " : " abnf" ,
199201 "name" : " ABNF"
200202 },
201203 {
202- "id " : " actionscript" ,
204+ "urlParam " : " actionscript" ,
203205 "name" : " ActionScript"
204206 }
205207]
206208```
207209
210+ ### List Spoken Languages
211+
212+ ** URL Endpoint:**
213+
214+ https://github-trending-api.now.sh/spoken_languages
215+
216+ ** Response:**
217+
218+ ``` json
219+ [
220+ {
221+ "urlParam" : " ab" ,
222+ "name" : " Abkhazian"
223+ },
224+ {
225+ "urlParam" : " aa" ,
226+ "name" : " Afar"
227+ },
228+ {
229+ "urlParam" : " af" ,
230+ "name" : " Afrikaans"
231+ },
232+ {
233+ "urlParam" : " ak" ,
234+ "name" : " Akan"
235+ }
236+ ]
237+ ```
238+
208239## NPM Package
209240
210241You could also use the API as a NPM package.
@@ -220,6 +251,7 @@ $ npm install --save @huchenme/github-trending
220251``` js
221252import {
222253 languages ,
254+ spokenLanguages ,
223255 fetchRepositories ,
224256 fetchDevelopers ,
225257} from ' @huchenme/github-trending' ;
@@ -233,6 +265,7 @@ fetchDevelopers({ language: 'javascript' }).then(developers => {
233265});
234266
235267console .log (languages);
268+ console .log (spokenLanguages);
236269```
237270
238271### API
@@ -244,32 +277,58 @@ List all languages
244277``` js
245278[
246279 {
247- id : ' 1c-enterprise' ,
280+ urlParam : ' 1c-enterprise' ,
248281 name: ' 1C Enterprise' ,
249282 },
250283 {
251- id : ' abap' ,
284+ urlParam : ' abap' ,
252285 name: ' ABAP' ,
253286 },
254287 {
255- id : ' abnf' ,
288+ urlParam : ' abnf' ,
256289 name: ' ABNF' ,
257290 },
258291 {
259- id : ' actionscript' ,
292+ urlParam : ' actionscript' ,
260293 name: ' ActionScript' ,
261294 },
262295];
263296```
264297
298+ #### spokenLanguages
299+
300+ List all spoken languages
301+
302+ ``` js
303+ [
304+ {
305+ urlParam: ' ab' ,
306+ name: ' Abkhazian' ,
307+ },
308+ {
309+ urlParam: ' aa' ,
310+ name: ' Afar' ,
311+ },
312+ {
313+ urlParam: ' af' ,
314+ name: ' Afrikaans' ,
315+ },
316+ {
317+ urlParam: ' ak' ,
318+ name: ' Akan' ,
319+ },
320+ ];
321+ ```
322+
265323#### fetchRepositories(params)
266324
267325Receive an array of trending repositories.
268326
269327** params** :
270328
271- - ` language ` : possible values are the the ones from ` fetchAllLanguages() ` or [ just find here] ( ./src/languages.ts ) .
329+ - ` language ` : possible values are the the ones from ` languages ` or [ just find here] ( ./src/languages.json ) .
272330- ` since ` : ` daily ` , ` weekly ` or ` monthly ` , default to ` daily ` .
331+ - ` spokenLanguageCode ` : possible values are the the ones from ` spokenLanguages ` or [ just find here] ( ./src/spoken-languages.json ) .
273332
274333``` js
275334[
@@ -303,7 +362,7 @@ Receive an array of trending developers.
303362
304363** params** :
305364
306- - ` language ` : possible values are the the ones from ` fetchAllLanguages() ` or [ just find here] ( languages.json ) .
365+ - ` language ` : possible values are the the ones from ` languages ` or [ just find here] ( languages.json ) .
307366- ` since ` : ` daily ` , ` weekly ` or ` monthly ` , default to ` daily ` .
308367
309368``` js
0 commit comments