Skip to content

samuraikun/graphql-ruby-hands-on

Repository files navigation

DevContainer for Ruby 3.3, Rails 7.1, graphql-ruby, and Sidekiq

devcontainer for Ruby3.3, Ruby on Rails 7.1

VSCode DevContainer

Install remote container

https://code.visualstudio.com/docs/remote/containers#_installation

Run DevContainer

  1. Open VSCode, then run Reopen in Container

Operation

Run Rails server

Run below command in terminal on the DevContainer

$ bin/rails db:seed
$ bin/rails s

GraphQL Playground

Access to http://0.0.0.0:3000/graphiql

Screenshot 2024-05-17 at 17 13 00

Type Checking

$ bundle exec rbs collection install

# rbs_rails
$ bin/rake rbs_rails:all

# Steep check
$ bundle exec steep check

Solargraph

# Generate documentation for bundled gems
$ bundle exec solargraph bundle

# Download Ruby core documentation
$ bundle exec solargraph download-core

Debugging

Run Run Debug (Shortcut key: F5)

VSCode Debugging

debugging

VSCode extensions

Architecture

Work on Docker Compose

References