Permalink
Browse files

adding a note/warning about subclassing in the initializer template

  • Loading branch information...
1 parent 3fb94d1 commit 88c55521095a5bd34a85871c41aa5ffa480e017a @justinfrench committed Dec 19, 2010
Showing with 8 additions and 0 deletions.
  1. +8 −0 lib/generators/templates/formtastic.rb
@@ -1,5 +1,13 @@
# encoding: utf-8
+# --------------------------------------------------------------------------------------------------
+# Please note: If you're subclassing Formtastic::SemanticFormBuilder in a Rails 3 project,
+# Formtastic uses class_attribute for these configuration attributes instead of the deprecated
+# class_inheritable_attribute. The behaviour is slightly different with subclasses (especially
+# around attributes with Hash or Array) values, so make sure you understand what's happening.
+# See the documentation for class_attribute in ActiveSupport for more information.
+# --------------------------------------------------------------------------------------------------
+
# Set the default text field size when input is a string. Default is nil.
# Formtastic::SemanticFormBuilder.default_text_field_size = 50

0 comments on commit 88c5552

Please sign in to comment.