aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2022-11-02 16:37:34 -0700
committerAdam Soltys <[email protected]>2022-11-02 16:37:34 -0700
commitb66477f0912349ef91adaff8c57ac787b5a56447 (patch)
treefb9c31e40e93c12a4382fb8b912c4f98a9bd09ef /src
parent602d8403006cb948ae85ce14e693f10a56852bd6 (diff)
downloadcoinos-ui-b66477f0912349ef91adaff8c57ac787b5a56447.tar.gz
coinos-ui-b66477f0912349ef91adaff8c57ac787b5a56447.zip
locations endpoint
Diffstat (limited to 'src')
-rw-r--r--src/routes/locations/+server.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/routes/locations/+server.js b/src/routes/locations/+server.js
new file mode 100644
index 00000000..381919ab
--- /dev/null
+++ b/src/routes/locations/+server.js
@@ -0,0 +1,7 @@
+import { get } from "$lib/utils";
+import { json } from '@sveltejs/kit';
+
+export async function GET({ fetch, setHeaders }) {
+ setHeaders({ 'cache-control': 'public, max-age=600' });
+ return json(await get('/locations'));
+}