I have an index page which shows a paged list of data from a database. When that list is empty, I want to show a "blank slate" view that clearly indicates to the user where they are and what they can do there: "You can add a new item by clicking here" type of thing.
Is there a better/cleaner way to do this than just having a big if statement around the entire page?
<% if (Model.Items.Count > 0) { %>
normal view
<% }
else { %>
blank slate view
<% } %>