New Discussion

Notifications

You’re not receiving notifications from this thread.

remove the class="simple-form"

8
Gems / Libraries

how to remove the class="simple-form" from a form created using the gem?

hello,
I've tried using /config/initializers/simple_form.rb
config.default_form_class = nil

and also:

<%= simple_form_for(resource, as: resource_name,
url: registration_path(resource_name), html: { class: nil, id: nil }) do |f| %>

the id has been removed, but the class remains

Try setting it to an empty string instead.

config.default_form_class = ' '
or
config.default_form_class = ' '

the class continues

the goRails login forms were created using simple-form-for?

Nope. I haven't used that gem in probably 10+ years.

See my last comment on how to disable that class with the deprecated config.

thanks, I'll take a look

Join the discussion
Create an account Log in

Want to stay up-to-date with Ruby on Rails?

Join 91,035+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.