aboutsummaryrefslogtreecommitdiff
path: root/src/z/rest.js
diff options
context:
space:
mode:
authorAlexander Rolley <arolley35@gmail.com>2026-08-05 17:25:27 +0200
committerAlexander Rolley <arolley35@gmail.com>2026-08-05 17:25:27 +0200
commitdc90bc811648da695e4cb47826ea6479cfd22a06 (patch)
tree3621725aadb61d267f1e88afb570a4ab3c824ab8 /src/z/rest.js
parent23ac91196552068d44bab5677a09a106b8172e27 (diff)
parent9b63c0f568832085b75ea6e3e983dc6cbeccfea4 (diff)
Merge branch 'dev' of https://git.nathanreiner.xyz/memora into develop
Diffstat (limited to 'src/z/rest.js')
-rw-r--r--src/z/rest.js20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/z/rest.js b/src/z/rest.js
new file mode 100644
index 0000000..c14944d
--- /dev/null
+++ b/src/z/rest.js
@@ -0,0 +1,20 @@
+
+const Rest = {
+ Request: class {
+ constructor(base) {
+ this.base = base;
+ }
+
+ get(url) { return fetch(url); }
+
+ post(url, body) {
+ return fetch(
+ url,
+ {
+ method: 'POST',
+ body: JSON.stringify(body),
+ }
+ );
+ }
+ },
+};