You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: guides/source/configuring.md
+12-12Lines changed: 12 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -48,11 +48,11 @@ Rails will use that particular setting to configure Active Record.
48
48
49
49
WARNING: Use the public configuration methods over calling directly to the associated class. e.g. `Rails.application.config.action_mailer.options` instead of `ActionMailer::Base.options`.
50
50
51
-
NOTE: If you need to apply configuration directly to a class, use a [lazy load hook](https://api.rubyonrails.org/classes/ActiveSupport/LazyLoadHooks.html) in an initializer to avoid auto-loading the class before initialization has completed. This will break because autoloading during initialization cannot be safely repeated when the app reloads.
51
+
NOTE: If you need to apply configuration directly to a class, use a [lazy load hook](https://api.rubyonrails.org/classes/ActiveSupport/LazyLoadHooks.html) in an initializer to avoid autoloading the class before initialization has completed. This will break because autoloading during initialization cannot be safely repeated when the app reloads.
52
52
53
53
### Rails General Configuration
54
54
55
-
These configuration methods are to be called on a `Rails::Railtie` object, such as a subclass of `Rails::Engine` or `Rails::Application`.
55
+
The following configuration methods are to be called on a `Rails::Railtie` object, such as a subclass of `Rails::Engine` or `Rails::Application`.
56
56
57
57
#### `config.after_initialize`
58
58
@@ -103,7 +103,7 @@ Is a flag. If `true` then any error will cause detailed debugging information to
103
103
104
104
#### `config.console`
105
105
106
-
Allows you to set class that will be used as console you run `bin/rails console`. It's best to run it in `console` block:
106
+
Allows you to set the class that will be used as console when you run `bin/rails console`. It's best to run it in the`console` block:
107
107
108
108
```ruby
109
109
console do
@@ -124,23 +124,23 @@ When `true`, eager loads all registered `config.eager_load_namespaces`. This inc
124
124
125
125
#### `config.eager_load_namespaces`
126
126
127
-
Registers namespaces that are eager loaded when `config.eager_load` is `true`. All namespaces in the list must respond to the `eager_load!` method.
127
+
Registers namespaces that are eager loaded when `config.eager_load` is set to `true`. All namespaces in the list must respond to the `eager_load!` method.
128
128
129
129
#### `config.eager_load_paths`
130
130
131
-
Accepts an array of paths from which Rails will eager load on boot if cache classes is enabled. Defaults to every folder in the `app` directory of the application.
131
+
Accepts an array of paths from which Rails will eager load on boot if `config.cache_classes`is set to `true`. Defaults to every folder in the `app` directory of the application.
132
132
133
133
#### `config.enable_dependency_loading`
134
134
135
-
When true, enables autoloading, even if the application is eager loaded and `config.cache_classes` is set as true. Defaults to false.
135
+
When true, enables autoloading, even if the application is eager loaded and `config.cache_classes` is set to `true`. Defaults to false.
136
136
137
137
#### `config.encoding`
138
138
139
139
Sets up the application-wide encoding. Defaults to UTF-8.
140
140
141
141
#### `config.exceptions_app`
142
142
143
-
Sets the exceptions application invoked by the ShowException middleware when an exception happens. Defaults to `ActionDispatch::PublicExceptions.new(Rails.public_path)`.
143
+
Sets the exceptions application invoked by the `ShowException` middleware when an exception happens. Defaults to `ActionDispatch::PublicExceptions.new(Rails.public_path)`.
144
144
145
145
#### `config.debug_exception_response_format`
146
146
@@ -153,7 +153,7 @@ Is the class used to detect file updates in the file system when `config.reload_
153
153
#### `config.filter_parameters`
154
154
155
155
Used for filtering out the parameters that you don't want shown in the logs, such as passwords or credit card
156
-
numbers. It also filters out sensitive values of database columns when call`#inspect` on an Active Record object. By default, Rails filters out passwords by adding `Rails.application.config.filter_parameters += [:password]` in `config/initializers/filter_parameter_logging.rb`. Parameters filter works by partial matching regular expression.
156
+
numbers. It also filters out sensitive values of database columns when calling`#inspect` on an Active Record object. By default, Rails filters out passwords by adding `Rails.application.config.filter_parameters += [:password]` in `config/initializers/filter_parameter_logging.rb`. Parameters filter works by partial matching regular expression.
157
157
158
158
#### `config.force_ssl`
159
159
@@ -173,7 +173,7 @@ Defines the verbosity of the Rails logger. This option defaults to `:debug` for
173
173
174
174
#### `config.log_tags`
175
175
176
-
Accepts a list of: methods that the `request` object responds to, a `Proc` that accepts the `request` object, or something that responds to `to_s`. This makes it easy to tag log lines with debug information like subdomain and request id - both very helpful in debugging multi-user production applications.
176
+
Accepts a list of methods that the `request` object responds to, a `Proc` that accepts the `request` object, or something that responds to `to_s`. This makes it easy to tag log lines with debug information like subdomain and request id - both very helpful in debugging multi-user production applications.
177
177
178
178
#### `config.logger`
179
179
@@ -726,8 +726,8 @@ When true, will always include column names in `SELECT` statements, and avoid wi
0 commit comments