question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[v2] Support index.md filenames / IDs

See original GitHub issue

🚀 Feature

Docusaurus v1 had a feature where creating an index.md file would generate an index.html file at the same, relative, directory path:

+ docs
   + getting-started
      + index.md (id: index)

generates

+ docs
   + getting-started
      + index.html

In v2, creating - using the docs plugin - an index.md file results in a structure of index/index.html.

+ docs
   + getting-started
      + index.md (id: index)

generates

+ docs
   + getting-started
      + index
        + index.html

This requires calling http://foo.bar/docs/getting-started/index or even http://foo.bar/docs/getting-started/index.html which is probably not intentional.

Have you read the Contributing Guidelines on issues?

yes

Motivation

Directory structure is important for SEO. Additionally, the index behavior is weird and (I think) unintentional as one ends up with urls like: http://foo.bar/docs/getting-started/index or http://foo.bar/docs/getting-started/index.html.

Pitch

I think Docusaurus v1 solved this correctly and this should be ported into v2 as well!

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:8
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

4reactions
aeneasrcommented, Apr 5, 2020

Maybe getting-started was a bad example, let’s take:

+ docs
  + index.md <- this one especially
  + sdks
    + index.md
    + golang.md
    + node.md
+ ...
2reactions
yangshuncommented, Apr 5, 2020

Makes sense 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

Autogenerated - Docusaurus
A category index document is a document following one of those filename conventions: Named as index (case-insensitive): docs/Guides/index.md ...
Read more >
Import - Dendron
The pod finds all files from the root , and copies over the files into your vault, cleaning the file names to fit...
Read more >
Markdown support - Doxygen Manual
Each file is converted to a page (see the page command for details). By default the name and title of the page are...
Read more >
How to use links in documentation - Contributor guide
This article provides guidance on creating links to other content on Microsoft Learn.
Read more >
Writing Your Docs - MkDocs
Therefore, MkDocs will allow you to name your index pages as README.md ... be sorted alphanumerically by file name (except that index files...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found