0

I'm trying to implement Redcarpet Markdown in my Rails project.

I have a class 'camp-description' which styles the paragraph. My problem is that when I add the markdown() inside my ERB tag then the styles of camp-description is not applied anymore.

This is my code:

<div class="panel">
    <h5>TRAINING CAMP PROGRAM</h5>
    <p class="camp-description"><%= markdown(@camp.agenda) %></p>
</div>

The output html looks like this:

enter image description here

How do I make sure that the markdown stays inside the 'camp-description' class and hence keep applying its styles?

Andy
  • 531
  • 1
  • 4
  • 19

0 Answers0