60 Experience
0 Lessons Completed
0 Questions Solved


I solved this by adding "raw" in the view and I can now paste embed code into active admin


is now

<%= raw(@post.content)%>

When I add the Youtube embed code. It displays it as a string on the front end.
The idea is that I could make this simple enough for the user updating the post to add the embed code easily themselves.

logo Created with Sketch.

Screencast tutorials to help you learn Ruby on Rails, Javascript, Hotwire, Turbo, Stimulus.js, PostgreSQL, MySQL, Ubuntu, and more. Icons by Icons8

© 2022 GoRails, LLC. All rights reserved.