About config/initializers
Rails automatically loads all the files inside config/initializers
folder.
This follows the principle of convention over configuration. We don't need to tell Rails to load which files. All files there are executed on server runs.
This encourages us create file for each initializing configurations. For example, we may have a file named assets.rb
to configure the assets pipeline compilations. Then we may have another file named devise.rb
to configure the Devise gem for user authentication.