//- vim:ts=4:sw=4: - let open_games = games.filter(game => game.status === 0) - let active_games = games.filter(game => game.status === 1) - let finished_games = games.filter(game => game.status === 2) doctype html html head include head title= SITE_NAME if active_games.length > 0 meta(http-equiv="refresh" content=600) body include header article.wide h1 Your games if open_games.length > 0 h2 Open +gamelist(open_games) p a(href="/create") Create a new game if active_games.length > 0 h2 Active +gamelist(active_games) if finished_games.length > 0 h2 Recently finished +gamelist(finished_games) if open_games.length === 0 && active_games.length === 0 && finished_games.length === 0 p Nothing here. p a(href="/games/finished") All your finished games