Module: VCFB::FormHelper
- Defined in:
- lib/vcfb/form_helper.rb
Instance Method Summary collapse
Instance Method Details
#component_form_with(model: nil, scope: nil, url: nil, format: nil, **options, &block) ⇒ Object
3 4 5 6 7 8 9 10 |
# File 'lib/vcfb/form_helper.rb', line 3 def component_form_with(model: nil, scope: nil, url: nil, format: nil, **, &block) [:builder] ||= VCFB::FormBuilder if [:builder].try(:form_component_defined?) render [:builder].form_component_class.new(model: model, scope: scope, url: url, format: format, **), &block else form_with(model: model, scope: scope, url: url, format: format, **, &block) end end |