node-ecstatic
node-ecstatic copied to clipboard
[Suggestion] What about template page for directory view?
@jfhbrook Now, view directory page generate by concatenation strings, so code for openDir
a bit complicated for perception. Maybe better use template page?
For example, concept of part of "handlebars" template page (.hbs) for generation table for directory files.
<table>
{{#each files}}
<tr>
<td>
<i class="icon {{iconType}}"></i>
</td>
<td class="perms">
<code>{{permissions}}</code>
</td>
<td class="file-size">
<code>{{size}}</code>
</td>
<td class="display-name">
<a href={{href}}>{{name}}</a>
</td>
</tr>
{{/each}}
</table>
In your opinion, whether or not to carry out such a change? P.S. Adding handlebars requires only 23 additional packages.