ruby on rails - Adding a css class to mapped elements -


i have code line on application users.skills.map {|m| m.name} returning user's skills.

i skills styled css styles , trying figure out on how can add style each 1 of skills. clue?

i not sure understand question, this:

users.skills.map {|m| "<p class='your_css_class'>#{m.name}</p>"} 

does work you?


Comments

Popular posts from this blog

php - render data via PDO::FETCH_FUNC vs loop -

c++ - OpenCV Error: Assertion failed <scn == 3 ::scn == 4> in unknown function, -

The canvas has been tainted by cross-origin data in chrome only -