Merge branch 'master' of git.wkit.fun:yutent/stats
commit
ad9dfdc157
|
@ -8,7 +8,7 @@
|
||||||
![top-langs](https://stats.wkit.fun/api/toplangs?username=${用户名}&count=${要显示的语言数量})
|
![top-langs](https://stats.wkit.fun/api/toplangs?username=${用户名}&count=${要显示的语言数量})
|
||||||
```
|
```
|
||||||
|
|
||||||
![demo](./preview/demo.png)
|
<img style="max-width:720px" src="https://stats.wkit.fun/api/toplangs?username=yutent&count=10">
|
||||||
|
|
||||||
|
|
||||||
### 接口
|
### 接口
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
script: bun ./app.js
|
script: bun ./app.js
|
||||||
cwd: ./
|
cwd: ./
|
||||||
watch: true
|
watch: true
|
||||||
name: stats:23333
|
name: stats:30303
|
||||||
ignore_watch: [data, public, package.json, package-lock.json, node_modules, .git, .gitignore, app.dev.yaml, app.yaml]
|
ignore_watch: [data, public, package.json, package-lock.json, node_modules, .git, .gitignore, app.dev.yaml, app.yaml]
|
||||||
exec_mode: fork
|
exec_mode: fork
|
||||||
|
|
||||||
|
|
2
app.yaml
2
app.yaml
|
@ -2,7 +2,7 @@
|
||||||
script: node ./app.js
|
script: node ./app.js
|
||||||
cwd: ./
|
cwd: ./
|
||||||
watch: true
|
watch: true
|
||||||
name: stats:23333
|
name: stats:30303
|
||||||
ignore_watch: [data, public, package.json, package-lock.json, node_modules, .git, .gitignore, app.dev.yaml, app.yaml]
|
ignore_watch: [data, public, package.json, package-lock.json, node_modules, .git, .gitignore, app.dev.yaml, app.yaml]
|
||||||
exec_mode: fork
|
exec_mode: fork
|
||||||
|
|
||||||
|
|
|
@ -74,6 +74,6 @@ query {
|
||||||
langs.sort((a, b) => b.size - a.size)
|
langs.sort((a, b) => b.size - a.size)
|
||||||
|
|
||||||
this.response.set('Content-Type', 'image/svg+xml')
|
this.response.set('Content-Type', 'image/svg+xml')
|
||||||
this.response.end(render({ langs: langs.slice(0, count) }, this.IS_MOBILE))
|
this.response.end(render({ title: `${username}'s Top Languages`, langs: langs.slice(0, count) }, this.IS_MOBILE))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
BIN
preview/demo.png
BIN
preview/demo.png
Binary file not shown.
Before Width: | Height: | Size: 29 KiB |
Loading…
Reference in New Issue