class Feedjira::Youtube::EntryParser

Constants

Public Instance Methods

content() click to toggle source
# File lib/feedjira/youtube/entry_parser.rb, line 20
def content
  %(#{player_html}<br/><br/>#{summary})
end
player_html() click to toggle source
# File lib/feedjira/youtube/entry_parser.rb, line 24
def player_html
  %(<iframe width="600" height="375" src="https://www.youtube.com/embed/#{youtube_video_id}" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>)
end
summary() click to toggle source
Calls superclass method
# File lib/feedjira/youtube/entry_parser.rb, line 11
def summary
  return if super.nil?

  super
    .delete("\r")
    .gsub("\n", "<br/>\n")
    .gsub(LINK_REGEXP) { %(<a href="#{$&}">#{$&}</a>) }
end