slidevjs / slidev

Presentation Slides for Developers
https://sli.dev
MIT License
32.82k stars 1.33k forks source link

Support custom slide routing (unique identification) #1799

Closed normal-coder closed 1 month ago

normal-coder commented 2 months ago

Is your feature request related to a problem? Please describe. When I am using Slidev to write slides, as I organize the content of the slides, the slide number of a specific content slide will occasionally change due to content adjustments. This is extremely inconvenient for me to navigate the slides using hyperlinks. This forces me to spend a lot of time and effort adjusting the link structure.

Describe the solution you'd like Assign a fixed identifier to a specific slide to identify its unique identity throughout the entire slide file.

Describe alternatives you've considered Through frontmatter, a slug or other identifier can be provided to replace the '/{slide number}' in the current URL, making it more semantic. This also facilitates the redirection of hyperlinks.

Maintaining the numerical numbering of the original introduction and allowing users to independently choose whether to enable custom slide identification/numbering may be an open approach

KermanX commented 1 month ago

There is a routeAlias option in every slide's config.