ts-safeql / safeql

Validate and auto-generate TypeScript types from raw SQL queries in PostgreSQL.
https://safeql.dev
MIT License
1.35k stars 22 forks source link
eslint eslint-plugin javascript lint postgres sql typescript

SafeQL - Automatic Type Inference & Validation for PostgreSQL Queries • Get started

npm version

https://user-images.githubusercontent.com/10504365/192807716-6a4fcbc1-9dc8-4d3b-a63b-2c95c0061689.mp4

Features

Install

I would first recommend follow the instructions in the documentation.

Prerequisites

  1. Set up ESLint following the typescript-eslint Getting Started docs, to enable TypeScript language support in ESLint
  2. Install the node-gyp prerequisites for your operating system
npm install --save-dev @ts-safeql/eslint-plugin libpg-query

Sponsors