LoginSignup
0
1

More than 3 years have passed since last update.

form_withにclassを適用する方法

Posted at

結論

fooというclassを適用させたい場合↓

<%= form_with(model: website, local: true, multipart: true,class:"foo") do |form| %>

これで適用されます。

因みに、form_withは画面幅いっぱい(100vw)のフォームが自動生成されてしまいますが、classを適用させて幅を変えれば解決です!

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1