AtDatabases

TypeScript clients for databases that prevent SQL Injection

README

@databases - SQL Libraries for Node.js that protect you from SQL Injection with support for Postgres, MySQL, SQLite and Expo/WebSQL

Safe From HTML Injection


Using tagged template literals for queries, e.g.

  1. ```ts
  2. db.query(sql`SELECT * FROM users WHERE id=${userID}`);
  3. ```

makes it virtually impossible for SQL Injection attacks to slip in un-noticed. All the @databases libraries enforce the use of the sql tagged template literals, so you can't accidentally miss them.

The query is then passed to your database engine as a separate string and values:

  1. ``` js
  2. {text: 'SELECT * FROM users WHERE id=?', values: [userID]}
  3. ```

Promises


All the @databases APIs are designed with promises in mind from the get go.

TypeScript


Written in TypeScript, so every module has type safety and type definitions built in.

Modular


Each database driver is published to npm as a separate module, so you don't need to install the ones you don't need.


Package Name | Version | Docs
@databases/migrations-base | NPM version | Not documented yet
@databases/mock-db | NPM version | Not documented yet
@databases/mock-db-typed | NPM version | Not documented yet
@databases/mysql-config | NPM version | Not documented yet
@databases/mysql-schema-cli | NPM version | Not documented yet
@databases/mysql-schema-introspect | NPM version | Not documented yet
@databases/mysql-schema-print-types | NPM version | Not documented yet
@databases/pg-config | NPM version | Not documented yet
@databases/pg-connection-string | NPM version | Not documented yet
@databases/pg-create | NPM version | Not documented yet
@databases/pg-data-type-id | NPM version | Not documented yet
@databases/pg-errors | NPM version | Not documented yet
@databases/pg-schema-cli | NPM version | Not documented yet
@databases/pg-schema-introspect | NPM version | Not documented yet
@databases/pg-schema-print-types | NPM version | Not documented yet
@databases/push-to-async-iterable | NPM version | Not documented yet
@databases/shared | NPM version | Not documented yet
@databases/shared-print-types | NPM version | Not documented yet
@databases/websql-core | NPM version | Not documented yet
@databases/with-container | NPM version | Not documented yet


Check out the website to learn more: https://www.atdatabases.org/