middleman-navtree icon indicating copy to clipboard operation
middleman-navtree copied to clipboard

Support Directory Indexes

Open bryanbraun opened this issue 9 years ago • 3 comments

This gem does not currently support directory indexes. That means that directory names cannot be links, only non-linked containers for grouping links.

Some people have use cases where linked directory names would be nice. Resolving this issue would fix:

  • https://github.com/bryanbraun/middleman-navtree/issues/8
  • https://github.com/bryanbraun/middleman-navtree/issues/11
  • And open the door to working on https://github.com/bryanbraun/middleman-navtree/issues/7

Approach It would be nice for this to smartly detect if a directory has an index file, but we can't as it's built right now. It's currently a recursive function that always creates the directory markup as a non-linked item. By the time we've entered a directory to see if it has an index file, the markup for the parent has already been written. We have to figure out a way to refactor this, or set directory indexes as an configurable option. The configurable option thing is kind of a bummer. It could be made a bit more smart by listening in for Middleman's activate :directory_indexes and swapping modes accordingly.

I'm open to suggestions. Not sure on the timeline of when I can address this, but it is a feature I'm interested in, if anybody wants to take a crack at it.

bryanbraun avatar Oct 15 '15 19:10 bryanbraun

+1

AntonKL avatar Oct 21 '15 21:10 AntonKL

This gem is dead? Any update about this?

equinusocio avatar Aug 08 '16 09:08 equinusocio

No updates on this feature as of yet.

I don't consider the gem "dead", given the attention I give to PRs and issues but I'm not actively developing this feature.

bryanbraun avatar Aug 12 '16 02:08 bryanbraun