// All posts
← homeWhat are joins in Ruby on Rails and how does it work?
joins - is a mechanism in Ruby on Rails that allows you to combine data from different database tables using SQL queries. They (j…
How does the has_many through association (many to many) work in Ruby on Rails?
In Ruby on Rails, `has_many through` is one of the association methods that allows establishing a connection between models throu…
What are attr_accessor, attr_reader, and attr_writer in Ruby? What are they used for?
In Ruby, attr_accessor is a macro (or method) for automatically creating a getter (method to access the value) and a setter (meth…
What is debugging?
Debugging is the process of identifying, analyzing, and correcting errors or defects in the software code. It is an important par…
What is the difference between <%, <%=, <%# and -%> in ERB templates (Ruby on Rails)?
In ERB (Embedded Ruby, *.erb files) templates used in Ruby on Rails, there are tags that define different types of embedded code:…
What is a loop in Javascript? How do for and while loops work in Javascript?
In JavaScript, a loop (loop or cycle, or as word formation says - kolobih) is a language construct that allows executing a block …
How to remove the space between inline and inline-block elements?
To remove the gap between `inline` and `inline-block` elements, one of the methods below may work for you:Method 1.Set a zero val…
What is Origin in Git?
In Git, "origin" is the name of a standard alias that is used to refer to the remote repository from which a clone was made. When…
How to use hex color codes in CSS with alpha values?
In CSS, there are several ways to represent colors that can be used. Common formats include RGB (red, green, blue), RGBA (red, gr…
How to disable File Upload in the Trix editor?
Trix - Rich Text Editor created by the Basecamp team (developers of Ruby on Rails). A decent editor if you don't need to do any s…
How to get a random logical value true or false in Ruby?
Sometimes you need to get a random boolean value true/false in Ruby. For example, when we are seeding a database in Rails and wan…
What to do if the webcam is not working on macOS?
In the last few years, I haven't encountered this problem on the new MacBook. But sometimes friends write to me who haven't updat…