Refactor everything that's used all over into a common/ package and sync files from static/ into public/ so that public's not in the git.

This commit is contained in:
Zed A. Shaw 2025-07-25 11:35:04 -04:00
parent d12817f4cc
commit ec7298cce0
36 changed files with 112 additions and 902 deletions

5
static/js/alpine.js Normal file

File diff suppressed because one or more lines are too long

21
static/js/code.js Normal file
View file

@ -0,0 +1,21 @@
class GetJson {
constructor(url) {
this.url = url;
this.items = [];
this.item = undefined;
}
async theData() {
const resp = await fetch(this.url);
console.assert(resp.status == 200, "failed to get it");
this.items = await resp.json();
return this.items;
}
async oneThing() {
this.item = await this.theData();
console.log("ITEMS", this.items);
return this.item;
}
}