Title: Auto header for each page · Issue #78 · docsifyjs/docsify · GitHub
Open Graph Title: Auto header for each page · Issue #78 · docsifyjs/docsify
X Title: Auto header for each page · Issue #78 · docsifyjs/docsify
Description: Take docisfy as an example: With loadSidebar enabled, in docs/_sidebar.md, we have: - Getting started - [Quick start](/quickstart) - [Writing more pages](/more-pages) - [Custom navbar](/custom-navbar) - [Cover page](/cover) ... The first...
Open Graph Description: Take docisfy as an example: With loadSidebar enabled, in docs/_sidebar.md, we have: - Getting started - [Quick start](/quickstart) - [Writing more pages](/more-pages) - [Custom navbar](/custom-navb...
X Description: Take docisfy as an example: With loadSidebar enabled, in docs/_sidebar.md, we have: - Getting started - [Quick start](/quickstart) - [Writing more pages](/more-pages) - [Custom navbar](/custom-navb...
Opengraph URL: https://github.com/docsifyjs/docsify/issues/78
X: @github
Domain: github.com
IPv4 address: 140.82.114.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Auto header for each page","articleBody":"Take `docisfy` as an example:\r\n\r\nWith `loadSidebar` enabled, in `docs/_sidebar.md`, we have:\r\n\r\n```\r\n- Getting started\r\n - [Quick start](/quickstart)\r\n - [Writing more pages](/more-pages)\r\n - [Custom navbar](/custom-navbar)\r\n - [Cover page](/cover)\r\n\r\n...\r\n```\r\n\r\nThe first line of `/quickstart` is `# Quick start`, and the first line of `/custom-navbar` is `# Custom navbar`, etc.\r\nIt would be great if we do not have to manually write these lines, since they can be inferred from the sidebar.\r\n\r\nIt has 3 advantages at least:\r\n- Save a line in each subpage, of course.\r\n- Whenever we want to change the header for a subpage, we only need to modify it in the sidebar, not both places. And the inconsistency can be avoided naturally.\r\n - For example, at the moment, docsify has `Writing more pages` for `/more-pages` in the sidebar, while the first line of `/more-pages.md` is `More pages`. Such inconsistency may not be desireable.\r\n- Be consistent with the behavior of Github Wiki.\r\n - In Github Wiki, a page named `Changelog`, which is actually a file `Changelog.md`, will have the header 'Changelog' automatically. We do not have to add a line `# Changelog` in the content. See [here](https://github.com/liulex/Snipaste-Feedback/wiki/Changelog) for an example.\r\n - If this feature is implemented, we will be able to directly use Github Wiki for docsify. For example, the md file for the link above is 'https://raw.githubusercontent.com/wiki/liulex/Snipaste-Feedback/Changelog.md'. We can alias `/Changelog` to it. Then we can have a Github Wiki (for community edit) and a doscify generated site at the same time!\r\n\r\nIn case I haven't made myself clear, the logic of this feature (maybe named `autoHeader`) is:\r\n\r\nIf `loadSidebar` and `autoHeader` are both enabled, for each link in `_sidebar.md`, prepend a header to the page before converting it to html.\r\n\r\nFor example, if `[Quick start](/quickstart)` is in `_sidebar.md`, we prepend a line `# Quick start` into `/quickstart.md` before we render `/quickstart.md` into html.","author":{"url":"https://github.com/liulex","@type":"Person","name":"liulex"},"datePublished":"2017-02-14T10:24:28Z","url":"https://github.com/docsifyjs/docsify/issues/78"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:a313c5f9-fd54-3373-d6e3-a25cea20e30a |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | DAAE:31A22B:1351949:19DF753:6B084F15 |
| html-safe-nonce | 3d0b20686869c457888d2e6b7157e9003fa8d09804897ce8238219cb2bbeec10 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEQUFFOjMxQTIyQjoxMzUxOTQ5OjE5REY3NTM6NkIwODRGMTUiLCJ2aXNpdG9yX2lkIjoiMTg3MjQ4NjA0NjQwODEzNDQyMSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | ec3de3aa02eb563193093d77af3ec0fb25a05bd94692f86a8b1ed762a6cc3d4a |
| hovercard-subject-tag | issue:207474765 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/docsifyjs/docsify/78/issue_layout |
| twitter:image | https://opengraph.githubassets.com/97b87ad0eccfbb525dd30352035ea19e0a6676875582e2328b2858b5112860a2/docsifyjs/docsify/issues/78 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/97b87ad0eccfbb525dd30352035ea19e0a6676875582e2328b2858b5112860a2/docsifyjs/docsify/issues/78 |
| og:image:alt | Take docisfy as an example: With loadSidebar enabled, in docs/_sidebar.md, we have: - Getting started - [Quick start](/quickstart) - [Writing more pages](/more-pages) - [Custom navbar](/custom-navb... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | liulex |
| hostname | github.com |
| expected-hostname | github.com |
| None | cbbe11c8d10ea79802eb945ca4f3b3b01420433f7b68eb53661ea0edfc88e7ea |
| turbo-cache-control | no-preview |
| go-import | github.com/docsifyjs/docsify git https://github.com/docsifyjs/docsify.git |
| octolytics-dimension-user_id | 40133106 |
| octolytics-dimension-user_login | docsifyjs |
| octolytics-dimension-repository_id | 74260508 |
| octolytics-dimension-repository_nwo | docsifyjs/docsify |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 74260508 |
| octolytics-dimension-repository_network_root_nwo | docsifyjs/docsify |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 208bbc93caa08d7cb0ee9d80cfde1fabfd516180 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width