Skip to content

Commit

Permalink
init commit
Browse files Browse the repository at this point in the history
  • Loading branch information
haorendashu committed Apr 11, 2024
1 parent e102658 commit 5122937
Show file tree
Hide file tree
Showing 4 changed files with 406 additions and 3 deletions.
6 changes: 6 additions & 0 deletions init.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
CREATE TABLE IF NOT EXISTS event (id text NOT NULL, pubkey text NOT NULL, created_at integer NOT NULL, kind integer NOT NULL, tags jsonb NOT NULL, content text NOT NULL, sig text NOT NULL);
CREATE UNIQUE INDEX IF NOT EXISTS ididx ON event(id);
CREATE INDEX IF NOT EXISTS pubkeyprefix ON event(pubkey);
CREATE INDEX IF NOT EXISTS timeidx ON event(created_at DESC);
CREATE INDEX IF NOT EXISTS kindidx ON event(kind);
CREATE INDEX IF NOT EXISTS kindtimeidx ON event(kind,created_at DESC);
39 changes: 39 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 7 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,12 @@
"test": "vitest"
},
"devDependencies": {
"wrangler": "^3.0.0",
"@cloudflare/vitest-pool-workers": "^0.1.0",
"vitest": "1.3.0",
"@cloudflare/vitest-pool-workers": "^0.1.0"
"wrangler": "^3.0.0"
},
"dependencies": {
"@noble/curves": "^1.4.0",
"@noble/hashes": "^1.4.0"
}
}
}
Loading

0 comments on commit 5122937

Please sign in to comment.