How to Configure Ruby Snippets for VS Code

Chris Demahy
1 min readJan 29, 2021

How to set-up snippets for Ruby (or any language) in Visual Studio Code

My Snippet for a new class when working in OO ruby

Recently while learning Object-Oriented ruby, I have learned that some pieces of code get written continuously over and over each time the developer wants to define a new class. When defining relationships in OO-Ruby, some instance and class definitions start to become tedious when writing a dozen new classes in a day.

Many of you now might be saying ‘Chris, vs code has ruby extensions that add these amazing snippets that add.…’ When you make your own their more useful… trust me

Thankfully, vs code has some features built-in that relieves the headaches of writing these same pieces of code over and over. We can take these pieces, or snippets, of code and teach them to VSCode so that we never have to write them fully again.

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

Chris Demahy
Chris Demahy

Written by Chris Demahy

Technology Enthusiast, Software Engineer, Git Issue Perfectionist.

No responses yet

Write a response