Our great sponsors
-
TypeORM
ORM for TypeScript and JavaScript. Supports MySQL, PostgreSQL, MariaDB, SQLite, MS SQL Server, Oracle, SAP Hana, WebSQL databases. Works in NodeJS, Browser, Ionic, Cordova and Electron platforms.
-
SurveyJS
Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.
Talking about synchronized schema, you can take a look at this PR (SeaQL/sea-orm#241). Like what you have said, the changes in database schema might cause unexpected compile error / behaviour in production. And this is what holding us back on this feature.
I've been bitten a few times by https://typeorm.io. The schema is declared in Entity class definitions. When the application connects to the database and the 'synchronize' option is enabled, the Entity definitions are compared to the DB schema and the DB schema columns are added/removed accordingly. This approach seems nice for development, but once an application hits production, it is easy to commit a change with synchronize=true, or to connect to a prod database with a development release. The risk is unexpected changes the schema, which could drop columns and cause chaos. IIRC, this is also a risk with SQLalchemy.
Related posts
- Show HN: Tsynamo – Type-friendly DynamoDB query builder for TypeScript
- Kysely – type-safe TypeScript SQL query builder
- any typescript users, that'd be interested in using oracledb with kysely (the type-safe query builder)?
- We migrated to SQL. Our biggest learning? Don't use Prisma
- Kysely - Typescript successor to Knex - `kysely-codegen` also generates types from your existing database.