github ts-safeql/safeql @ts-safeql/eslint-plugin@0.0.5

latest releases: @ts-safeql/test-utils@0.0.30, @ts-safeql/shared@3.4.7, @ts-safeql/generate@3.4.7...
2 years ago

Patch Changes

  • 30c5b98: Tag-only types are now available using the "tagName" setting:

    For example (Postgres.js):

    {
      "databaseUrl": "postgres://postgres:postgres@localhost:5432/safeql_postgresjs_demo",
      "tagName": "sql",
      "transform": "${type}[]"
    }
    import { sql } from "postgres";
    
    const query = sql`SELECT id FROM users`;
                  ^^^ // Error: Query is missing type annotation
    
    // After: ✅
    const query = sql<{ id: number; }[]>`SELECT id FROM users`;

Don't miss a new safeql release

NewReleases is sending notifications on new releases.