aboutsummaryrefslogtreecommitdiffstats
path: root/railties/guides/source/configuring.textile
diff options
context:
space:
mode:
authorRyan Bigg <radarlistener@gmail.com>2010-11-26 17:03:14 +1100
committerRyan Bigg <radarlistener@gmail.com>2010-11-26 17:03:14 +1100
commit72e973ebbcddbeb172c2dd3a7ddc12957dc5bec0 (patch)
tree59a57023897a61b872d4103bc0d842579f383aee /railties/guides/source/configuring.textile
parent6bb462861f7cca070f1d3933c19c10b18fa44c9e (diff)
downloadrails-72e973ebbcddbeb172c2dd3a7ddc12957dc5bec0.tar.gz
rails-72e973ebbcddbeb172c2dd3a7ddc12957dc5bec0.tar.bz2
rails-72e973ebbcddbeb172c2dd3a7ddc12957dc5bec0.zip
Add mention of after_initialize to the config guide
Diffstat (limited to 'railties/guides/source/configuring.textile')
-rw-r--r--railties/guides/source/configuring.textile8
1 files changed, 8 insertions, 0 deletions
diff --git a/railties/guides/source/configuring.textile b/railties/guides/source/configuring.textile
index 3986faa3cd..154eebc0c1 100644
--- a/railties/guides/source/configuring.textile
+++ b/railties/guides/source/configuring.textile
@@ -39,6 +39,14 @@ Rails will use that particular setting to configure Active Record.
h4. Rails General Configuration
+* +config.after_initialize+ takes a block which will be ran _after_ Rails has finished initializing. Useful for configuring values set up by other initializers:
+
+<ruby>
+ config.after_initialize do
+ ActionView::Base.sanitized_allowed_tags.delete 'div'
+ end
+</ruby>
+
* +config.autoload_once_paths+ accepts an array of paths from which Rails will automatically load from only once. All elements of this array must also be in +autoload_paths+.
* +config.autoload_paths+ accepts an array of additional paths to prepend to the load path. By default, all app, lib, vendor and mock paths are included in this list.