use jade compiled function for dynamic client-side template rendering