how to add a class to the input component in a wrapper in simple_form 2

前端 未结 5 1062
难免孤独
难免孤独 2021-02-04 04:57

I am trying to have class=\"text\" in my input fields when using a custom wrapper called :hinted in simple_form 2.0.0.rc

config.wrappers :hinted do          


        
5条回答
  •  说谎
    说谎 (楼主)
    2021-02-04 06:03

    You can setup this in simple_form initializer:

    config.input_class = 'foo'

    It works for me :)

提交回复
热议问题