local util = require("util")
local tile = require('page/partial/tile')
--if not app.cache['experiences.html'] and util.count(app.cache.items) > 0 then
-- print("processing! " .. util.count(app.cache.items) .. " items")
-- app.cache['experiences.html'] = util.memoize(
-- function()
-- local data = util.merge({tiles=''},{ opts = app.opts })
-- foreach(app.cache.items, function(k,v)
-- data.tiles = data.tiles .. tile( util.flatten(v,"item") )
-- end)
-- local html = util.template( LoadAsset("page/experiences.html"),data)
-- return html
-- end,
-- 60*5 -- re-run every 5 mins (otherwise return cache)
-- )
--end
if util.count(app.cache.items) == 0 then
SetStatus(200)
SetHeader('Content-Type', 'text/html; charset=utf-8')
local html = util.template( [[
${header}