ruby 3 and rails7 and graphql 2
https://gorillalogic.com/blog/how-to-make-data-fetching-easier-using-ruby-on-rails-7-with-graphql
https://www.honeybadger.io/blog/graphql-apis-for-rails/
https://www.apollographql.com/blog/using-graphql-with-ruby-on-rails
https://evilmartians.com/chronicles/graphql-on-rails-1-from-zero-to-the-first-query
基本的query\create\update等示例.
还有些一些n+1查询,多条件查询和前端自定义排序等问题.
some code:
https://www.honeybadger.io/blog/graphql-apis-for-rails/
https://www.apollographql.com/blog/using-graphql-with-ruby-on-rails
https://evilmartians.com/chronicles/graphql-on-rails-1-from-zero-to-the-first-query
基本的query\create\update等示例.
还有些一些n+1查询,多条件查询和前端自定义排序等问题.
some code:
rails new taypi -d postgresql --skip-action-mailbox --skip-action-text --skip-spring --webpack=react -T
rails db:create db:migrate db:seed rails generate graphql:install bundle add graphql rails generate model Posts author title body:text rails generate model Comments author body:text post:references has_many :comments, :dependent => :delete_all rails g graphql:object post rails g graphql:object comment field :post, Types::PostType field :comments, [Types::CommentType] rails g graphql:mutation create_post rails g graphql:input postrails g graphql:input comment argument :comments, [Types::CommentInputType], required: false
阅读量: 880
发布于:
修改于:
发布于:
修改于: