1
0
mirror of https://git.tuxpa.in/a/code-server.git synced 2025-01-09 09:48:45 +00:00
code-server-2/src/node/routes/apps.ts

18 lines
370 B
TypeScript
Raw Normal View History

import * as express from "express"
import { PluginAPI } from "../plugin"
/**
* Implements the /api/applications endpoint
2020-11-04 02:49:10 +00:00
*
* See typings/pluginapi.d.ts for details.
*/
export function router(papi: PluginAPI): express.Router {
const router = express.Router()
router.get("/", async (req, res) => {
res.json(await papi.applications())
})
2020-11-04 02:53:16 +00:00
return router
}