Skip to content

Instantly share code, notes, and snippets.

@neudabei
Last active Aug 14, 2018
Embed
What would you like to do?
fl_medium_blogpost
# ...
{ fields:
subject_categories.map do |sc|
selected = interested_subject_categories.include?(sc)
{ title: sc.title, value: sc.id.to_s, selected: selected }
end
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment