kastor0.2.0
Get started

INDEXField notes

kastor guides

A few longer reads on problems every data layer meets: N+1 queries, migrations, seed data and running on more than one database.

Guias em português

Field notes

Migrate to kastor

GUIDE 05Migrate from Prisma to kastorConvert schema.prisma with one command, map client calls one to one, and keep your data and migration history.16 min read GUIDE 06Migrate from Drizzle ORM to kastorMap table definitions, filters and relational queries to kastor, move to kastor migrations and keep your data.12 min read GUIDE 07Migrate from TypeORM to kastorEntities to a TypeScript schema, repositories and the query builder to findMany and include, and the migration history.13 min read GUIDE 08Migrate from Sequelize to kastorModels to a TypeScript schema, Op filters to where objects, includes, transactions, hooks and the migration history.12 min read GUIDE 09Migrate from Knex to kastorReplace builder chains with typed findMany and include, keep raw SQL where it helps, and baseline the existing migrations.11 min read GUIDE 10Migrate from Mongoose to kastorMove to kastor on the same MongoDB data: schemas, populate, ObjectId references, validators and indexes.12 min read GUIDE 11Coming from Laravel and Eloquentkastor runs in JavaScript runtimes, not PHP. How models, relations, scopes, migrations and seeders map, or how to share the database.14 min read GUIDE 12Coming from the Django ORMkastor runs in JavaScript runtimes, not Python. How models, QuerySets, migrations and fixtures map, or how to share the database.13 min read GUIDE 13Coming from Rails and Active Recordkastor runs in JavaScript runtimes, not Ruby. How models, associations, scopes, migrations and seeds map, or how to share the database.13 min read

Framework guides

GUIDE 14kastor with the Next.js App RouterOne client across hot reloads, server components, server actions, route handlers and the edge runtime.12 min read GUIDE 15kastor with NuxtA client in server/utils, typed server routes, runtimeConfig for secrets, a Nitro close hook and migrations on deploy.10 min read GUIDE 16kastor with SvelteKitA client in $lib/server, typed load functions, form actions, endpoints, private env vars and migrations.10 min read GUIDE 17kastor with Remix and React RouterA .server module, typed loaders and actions, hot reload safe pooling, env vars and migrations on deploy.10 min read GUIDE 18kastor with AstroServer rendered pages, endpoints and actions with typed queries, a reused client, server only env vars and migrations.10 min read GUIDE 19kastor with NestJSA global module with a provider token, ConfigService, shutdown hooks, typed services, an exception filter and migrations.11 min read GUIDE 20kastor with ExpressOne client per process, async routes, an error middleware for KastorError codes, graceful shutdown and migrations.10 min read GUIDE 21kastor with FastifyA plugin that decorates the instance with a typed client, onClose cleanup, validated routes and migrations.10 min read GUIDE 22kastor with HonoA typed db variable set by middleware, one client on servers, a client per request on Workers, and migrations.10 min read GUIDE 23kastor with AdonisJSValidated env vars, a service module, a provider for shutdown, typed controllers and migrations in CI.10 min read GUIDE 24kastor with Bunbun:sqlite with nothing to install, Postgres through pg, Bun.serve routes, hot reload safe reuse and migrations.9 min read GUIDE 25kastor with Denonpm specifiers in deno.json, a typed client with pg, Deno.serve routes, permissions, env files and migrations.9 min read GUIDE 26kastor on Cloudflare WorkersA client per request from D1, Postgres through Hyperdrive, Turso over HTTP, typed bindings and migrations.11 min read GUIDE 27kastor with Electron and SQLitebetter-sqlite3 in the main process, the database in userData, typed IPC through a preload bridge and migrations on startup.11 min read GUIDE 28kastor on AWS LambdaA client reused across warm invocations, small pools behind RDS Proxy, secrets, bundling and migrations.11 min read

Suggestions

Kas looked under every log. Nothing matches that yet.

Try a method name, a database or a framework.