All New

user:thomas gists created by user

title:mygist gists with given title

filename:myfile.txt gists having files with given name

extension:yml gists having files with given extension

language:go gists having files with given language

topic:homelab gists with given topic

Login


All New Login

All gists

Recently created
Least recently created
Recently updated
Least recently updated

xiongxiao / say.html

0 likes
0 forks
1 files
Last active 1762870021
1 <body>
2 <div id="content"></div>
3 <script>
4 const url = new URL('/api/v1/saying', 'https://uapis.cn/');
5 const res = fetch(url, {
6 method: 'GET',
7 headers: {
8 'Content-Type': 'application/json',
9 },
10 }).then(response => response.json())

xiongxiao / process-fork-call.ts

0 likes
0 forks
1 files
Last active 1760549903
1 import { App } from '@kevisual/router'
2 import { fork } from 'child_process'
3 const app = new App()
4 import path from 'path'
5
6 // http://localhost:3000/api/router?path=call
7 app.route({
8 path: 'call'
9 }).define(async (ctx) => {
10 ctx.body = 'Hello World'

xiongxiao / gol.ts

0 likes
0 forks
1 files
Last active 1758299995
1 export const getJOLTime = () => {
2 /* q = d - 1324 * 24 * 60 * 60
3 * 1443365529298 是第一天
4 * Sun Sep 27 2015 22:52:09 GMT+0800 (中国标准时间)
5 */
6 let now = new Date()
7 let show_day = ["星期天", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六"]
8 let manyDay = Math.floor((now - 1443365529298) / (24 * 60 * 60 * 1000)) + 1// 往下 取整
9 let day = now.getDay()
10 const text = `今天是JOL的第 ${manyDay} 天,${show_day[day]}`

xiongxiao / test.ts

0 likes
0 forks
1 files
Last active 1758298226
1 console.log('test')
Newer Older

Powered by Opengist ⋅ Load: 46ms⋅

日本語
Čeština Deutsch English Español Français Magyar Italiano 日本語 Polski Português Русский Türkçe Українська 中文 繁體中文