xcatliu / pagic

A static site generator powered by Deno + React
https://pagic.org
MIT License
1.65k stars 103 forks source link

How do I create an index.html to lists all the other pages #15

Closed kasajian closed 4 years ago

kasajian commented 7 years ago

I want to create a landing index.html page, so I create an index.md file. Within it, I want to have a list of links to the other html files. I'm willing to do this in JavaScript. Can we have a variable and gets injected which is the list of the other html files?

Perhaps the easiest thing to do is to pass in the a list of files, in a hierarchy, starting with the public root folder.

xcatliu commented 7 years ago

Thanks for your advice, I've been thinking about adding this feature. It will be in next version.

xcatliu commented 4 years ago

Use sidebar plugin and then you will get a sidebar props. Live demo: https://github.com/xcatliu/typescript-tutorial/blob/master/_sidebar.tsx