mirror of
https://github.com/cupcakearmy/fantus.git
synced 2024-11-01 13:04:34 +01:00
15 lines
344 B
TypeScript
15 lines
344 B
TypeScript
|
import { NextApiRequest, NextApiResponse } from 'next'
|
||
|
import getConfig from 'next/config'
|
||
|
|
||
|
const config = getConfig().serverRuntimeConfig
|
||
|
|
||
|
|
||
|
export default async (req: NextApiRequest, res: NextApiResponse) => {
|
||
|
try {
|
||
|
res.send(JSON.stringify(config))
|
||
|
res.status(200).end()
|
||
|
|
||
|
} catch {
|
||
|
res.status(400).end()
|
||
|
}
|
||
|
}
|