Default disable_with for simple_form submit
问题 I want to change the default behavior of my submit button in simple_form so that I needn't explicitly specify :disable_with => true for all my forms. How can I make this particular change in the simple_form.rb? 回答1: This is a little different in newer versions of Rails, as setting the property disable_with is deprecated. I wrote an article on this: http://www.railsonmaui.com/blog/2014/02/23/simple-form-and-disable-processing-by-default/ Here's the new code: SimpleForm::FormBuilder.class_eval