How can I add placeholder text to my f.text_field fields so that the text comes pre-written by default, and when a user click inside the fields, the te
placeholder
f.text_field
For those using Rails(4.2) Internationalization (I18n):
Set the placeholder attribute to true:
f.text_field :attr, placeholder: true
and in your local file (ie. en.yml):
en: helpers: placeholder: model_name: attr: "some placeholder text"