kopia lustrzana https://github.com/badgen/badgen.net
feat: update runkit schema #24
rodzic
af18f4da96
commit
6cdee9b71a
|
@ -1,7 +1,15 @@
|
|||
const axios = require('../axios.js')
|
||||
|
||||
module.exports = async function (account, notebook, ...args) {
|
||||
const endpoint = `https://runkit.io/${account}/${notebook}/branches/master?args=${args.join('/')}`
|
||||
/**
|
||||
* EXAMPLES
|
||||
*
|
||||
* /runkit/satisfaction-flq08o9mm3ka/102909/employee
|
||||
* /runkit/satisfaction-flq08o9mm3ka/102909/people
|
||||
* /runkit/satisfaction-flq08o9mm3ka/102909/topic
|
||||
*/
|
||||
|
||||
module.exports = async function (endpointId, ...args) {
|
||||
const endpoint = `https://${endpointId}.runkit.sh/${args.join('/')}`
|
||||
const { subject, status, color } = await axios(endpoint).then(res => res.data)
|
||||
|
||||
if (subject && status) {
|
||||
|
|
Ładowanie…
Reference in New Issue