Skip to content

Commit 9a301cd

Browse files
committed
Add aliased_fields example in README.md
1 parent f6fea91 commit 9a301cd

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

README.md

+2
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@ class User(SQLAlchemyObjectType):
4747
only_fields = ("name",)
4848
# exclude specified fields
4949
exclude_fields = ("last_name",)
50+
# alias specified fields
51+
aliased_fields = {'name': 'first_name'}
5052

5153
class Query(graphene.ObjectType):
5254
users = graphene.List(User)

0 commit comments

Comments
 (0)