Set up:
- Install the Ruby Solargraph VS Code extension and disable
Use Bundler - Run
$ gem install solargraph solargraph-rails - Update the Ruby Solargraph VS Code extension's command path to point to the abolute path of your solargraph install. (e.g.
/Users/justin/.rbenv/shims/solargraph) - Add the contents of this gist to the root of the project and git ignore them
- In your project root run
$ solargraph bundle - In your project root run
$ yard gems - Run the
Developer: Reload Windowcommand for VS Code
Verify
- Visit your
app/models/application_record.rb - Navigate over the
BaseinApplicationRecord::Base - Right-click
Peek->Peek Definitionand the pop-up view should include a reference tobase.rbfrom inside the `activerecord gem
Does someone who copies this need to run
solargraph bundleandyard gemson a regular basis?