vsoch / docsy-jekyll

A Jekyll version of the beautiful Docsy!
https://vsoch.github.io/docsy-jekyll/
Apache License 2.0
199 stars 142 forks source link

Subfolder does not display content, but shows 404 when viewed from nested page #58

Closed mccurcio closed 3 years ago

mccurcio commented 3 years ago

I am having trouble viewing subfolders after I have drilled down to content. For example, when I am viewing there is the pseudo-path above it, [Documentation / Subfolder / A Nested Page]. If I want to open the subfolder I get a 404 error and not the content of the subfolder as I would expect. I would like to have my folder open with the contents showing, similar to the document page that shows the md files. Originally I added an 'index.md' file into each folder with a re-direct sending the viewer back to the home/index page. This did not work. Is there something I am missing or is this an issue? Thank you M

vsoch commented 3 years ago

You're totally right! Check out this example https://vsoch.github.io/docsy-jekyll/docs/subfolder rendered from https://github.com/vsoch/docsy-jekyll/blob/master/_docs/subfolder.md. In summary - you name a markdown file the "same" as the folder (and at the same root) for it to appear as an index for that page/url.

mccurcio commented 3 years ago

Hi V, I'm sorry, I still can't get it to work for me.

vsoch commented 3 years ago

The pages are there:

As for the breadcrumb It's likely the trailing slash (try removing it). Some browsers will treat them identically (e.g., subfolder/ vs subfolder) but others do not. If you'd like to submit a PR to remove the slash from the breadcrumb I'd be happy to review.

mccurcio commented 3 years ago

Hi V, Thanks for the offer. Let me play around with this first. I'm not sure it is a slash issue but let me convince myself either way. Can I keep this open until then? ;^)

vsoch commented 3 years ago

Yep sure thing. If it helps look in the _site folder to see the raw files that are rendered.

mccurcio commented 3 years ago

Hi V, Yes, it was the 'slashes' that threw a spanner in the works. Also, I have a question, would you mind if I tried to expand the documentation for your repo? I have been working with some friends on Hacktober fest and I thought I could help. However, to get 'credit' for the points I need to get pull requests from 'Hacktober fest-sites'. Would you be interested in signing up? TY

vsoch commented 3 years ago

Yes I'd love to support you to do that! I'll add the topic to the repository.