Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
Update the SQL schema to include the inflection comment directive, especially since the screenshot below has inflected field and type names.
  • Loading branch information
MrPiao authored Feb 25, 2025
1 parent 2b68b46 commit 09e36c3
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,11 @@ create table blog_post(
created_at timestamp not null,
updated_at timestamp not null
);

-- This enables default inflection, which automatically renames
-- snake_case to PascalCase for type names, and snake_case to camelCase for field names.
-- See https://supabase.github.io/pg_graphql/configuration/#inflection for more details.
COMMENT ON SCHEMA public IS e'@graphql({"inflect_names": true})';
```
Translates into a GraphQL schema displayed below.

Expand Down

0 comments on commit 09e36c3

Please sign in to comment.