Skip to content

Generate an interface with the generated methods? #2831

Answered by kyleconroy
pengux asked this question in Q&A
Discussion options

You must be logged in to vote

The emit_interface option does exactly what you want.

{
  "version": "1",
  "packages": [
    {
      "path": "db",
      "engine": "postgresql",
      "schema": "query.sql",
      "queries": "query.sql",
      "emit_interface": true
    }
  ]
}

https://play.sqlc.dev/p/1f0fc5978c9788beadd198a562fea3f3ed073dc3b4eaca63cfe9c84eb7655e20

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@pengux
Comment options

Answer selected by kyleconroy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
enhancement New feature or request
2 participants
Converted from issue

This discussion was converted from issue #2827 on October 11, 2023 16:52.