Home / Interview / Rails :: General Questions

Interview :: Rails

1)

What is Ruby on Rails?

Ruby on Rails is a server-side web application development framework written in Ruby language. It allows you to write less code than other languages and frameworks. It includes everything needed to create database-backed web applications according to MVC pattern.

2)

Explain DRY in Rails?

DRY stands for Don't Repeat Yourself. It is a principle of software development which states that "Every piece of knowledge must have an authoritative, unambiguous, single representation within a system. If the same part of the code will not repeat again and again, the code will be more maintainable, extensible and less buggy.

3) What is the current version of Ruby on rails?

Rails 5.0.1 was released on December 21, 2016. It introduced Action cable, Turbolinks 5 and API mode.

4)

Explain CoC in Rails ?

DRY stands for Convention over Configuration. It provides different opinions on the best way to do many things in a web application.

5)

Who developed Rails?

Ruby on Rails was created by David Heinemeier Hansson (DHH).

6)

What are the three methods to install Ruby on Rails?

There are three methods to install Ruby on Rails:

  • Using rbenv (recommended)
  • Using rvm
  • From source

7)

Name some Rails IDE or editor?

Ruby on Rails can be used with either a simple text editor or with an IDE.

Some of the Rails IDEs are listed below:

  • TextMate
  • E
  • Intellij IDEA
  • NetBeans
  • Eclipse
  • Heroku
  • Aptana Studio
  • RubyMine
  • Kuso IDE
  • Komodo
  • Redcar
  • Arcadia
  • Ice Coder

8)

What is Rails script? Name some of them?

Rails provide some excellent tools that are used to develop a Rails application. These tools are packaged as scripts from command line.

Following are the most useful Rails scripts used in Rails application:

  • Rails Console
  • WEBrick Web Server
  • Generators
  • Migrations

9)

Are there any disadvantages of Ruby on Rails? If yes, mention them?

Some of the features that are not supported by Ruby on rails are:

  • Linking to multiple databases.
  • Inclusion of foreign keys in database.
  • Establishing connection to various databases at a time.
  • Web services related to Soap.

10) What is the use of the super function in Ruby on Rails?

The super function in Ruby is used to invoke the original method. It calls the superclass implementation of the current method.