PgTyped logo

PgTyped

Typesafe SQL in TypeScript and Postgres
2
10
+ 1
0

What is PgTyped?

It makes it possible to use raw SQL in TypeScript with guaranteed type-safety. No need to map or translate your DB schema to TypeScript, it automatically generates types and interfaces for your SQL queries by using your running Postgres database as the source of type information.
PgTyped is a tool in the Database Tools category of a tech stack.
PgTyped is an open source tool with 2.8K GitHub stars and 87 GitHub forks. Here’s a link to PgTyped's open source repository on GitHub

Who uses PgTyped?

PgTyped Integrations

PgTyped's Features

  • Automatically generates TS types for parameters/results of SQL queries of any complexity
  • Supports extracting and typing queries from both SQL and TS files
  • Generate query types as you write them, using watch mode
  • Useful parameter interpolation helpers for arrays and objects
  • No need to define your DB schema in TypeScript, your running DB is the live source of type data
  • Prevents SQL injections by not doing explicit parameter substitution. Instead, queries and parameters are sent separately to the DB driver, allowing parameter substitution to be safely done by the PostgreSQL server

PgTyped Alternatives & Comparisons

What are some alternatives to PgTyped?
JavaScript
JavaScript is most known as the scripting language for Web pages, but used in many non-browser environments as well such as node.js or Apache CouchDB. It is a prototype-based, multi-paradigm scripting language that is dynamic,and supports object-oriented, imperative, and functional programming styles.
Git
Git is a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency.
GitHub
GitHub is the best place to share code with friends, co-workers, classmates, and complete strangers. Over three million people use GitHub to build amazing things together.
Python
Python is a general purpose programming language created by Guido Van Rossum. Python is most praised for its elegant syntax and readable code, if you are just beginning your programming career python suits you best.
jQuery
jQuery is a cross-platform JavaScript library designed to simplify the client-side scripting of HTML.
See all alternatives

PgTyped's Followers
10 developers follow PgTyped to keep up with related blogs and decisions.