m-chrzan.xyz
aboutsummaryrefslogtreecommitdiff
path: root/lib/html.rb
blob: 61e25a31f68df29d997a5b227ef9a98d17035254 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
require './lib/templated'

def render_html song
  template = html_template 'song'
  template.result binding
end

def make_htmls songs
  songs.each do |song_id, song|
    content = render_html song
    write_templated content, song_html(song_id), song.title
  end
end