1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Document Action Text rich_text field attribute [ci skip]

Similar to: #42391
This commit is contained in:
Abhay Nikam 2021-06-04 22:45:56 +05:30
parent 96f2cd010e
commit ae8e593dc7

View file

@ -83,6 +83,12 @@ class Message < ApplicationRecord
end
```
or add rich text field while creating a new model using:
```
bin/rails generate model Message content:rich_text
```
**Note:** you don't need to add a `content` field to your `messages` table.
Then use [`rich_text_area`] to refer to this field in the form for the model: