Responding with Rich Text

Allowing admins to respond

To allow our admins to respond to support requests, we’ll need to make a new UI for them to see the requests that need a response, a way for them to provide a response, and some code to email the customer back. We know how to do all of these things, so this is a great opportunity to learn about Action Text, which is a Rails library that allows us to easily provide a rich-text editing experience. We can use this to allow our admins to write a fully formatted response and not just plain text.

Let’s first quickly create the UI where we’ll see the support requests and edit them. This should be o familiar to us by now, so we’ll move quickly. Add a new route to config/routes.rb for the index() and update() methods:

Get hands-on with 1200+ tech skills courses.