We should be able to pass in the index of the section we want and get only that section, or multiple sections. This makes it easier to split up the blog sections. In scalar context, should return the number of sections.
Where right now we must:
% my @sections = $page->section;
% for my $i ( 0..$#sections ) {
<section id="section-<%= $i %>">
<%= $sections[ $i ] %>
</section>
% }
We should be able to pass in the index of the section we want and get only that section, or multiple sections. This makes it easier to split up the blog sections. In scalar context, should return the number of sections.
Where right now we must:
With this change we can:
This is helpful when making links to sections, and seems easier to understand to me.