This directory is similar to an Architectural Decision Record, but with more emphasis on being current and up to date, rather than recording past decisions. If you wanna view the evolution of a decision, use git.
The primary author of Pentive, Alex, is not a good architect, designer, or web dev. Please open an issue if you see areas for improvement!
The multitude of services is partly due to separating endpoints that serve insecure user generated content from trusted Pentive content.
😭 Trust me, I never thought I'd willingly write TypeScript/JavaScript (same thing).
- The client-side occasionally-online SRS that stores a user's templates/notes/cards
- Where card reviews occur
- A small occasionally-online static site that displays untrusted user generated content (e.g. users' cards)
- Typically viewed through an iframe on
app
so JavaScript can't accessapp
- Has a service worker that queries
app
for media (e.g. images)
- The server-side always-online collaboration platform
- Where users may optionally upload notes for sharing
- Its raison d'être is the same as
app-ugc
's - but forhub
- Always-online, so it doesn't need
app-ugc
's fancy service worker
- short for (AWS) Lambda-RPC
- Mostly empty for now, except for the Prisma/PlanetScale schema
- Server-side syncing may eventually be implemented here
- short for Cloudflare Worker API
- How
app
submits changes tohub
/PlanetScale
- The API serving untrusted user generated content from a secondary domain (e.g.
user-generated-content-pentive.com
) - This is the API - the other
ugc
s are sites (typically viewed through iframes)
- PeerServer that establishes p2p connections between Pentive apps for syncing client-side databases
- A library of shared code for the above services