diff --git a/README.md b/README.md index bcd558e..cf4ab46 100644 --- a/README.md +++ b/README.md @@ -37,6 +37,12 @@ Call `preload` when defining your field: # Post.includes(:comments) preload :comments + # Post.includes(:comments, :authors) + preload [:comments, :authors] + + # Post.includes(:comments, authors: [:posts, :followers]) + preload [:comments, { authors: [:posts, :followers] }] + resolve ->(obj, args, ctx) { obj.comments } end end