Expose method to generate slug #1056
marceloverdijk
started this conversation in
Proposal
Replies: 1 comment 1 reply
-
Can you please use the template we provide? Regarding the proposal, you might want to add some code to better frame the suggestion, it's not very clear how/when someone would use this function |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Internally Astro definitely has a slug generator.
It would be nice to expose this so users can generate a slug from a string text (eg a blog category like “Health Improvements” becomes “health-improvements”).
I can easily create a custom slugify function or use an external dependency, but as Astro already does this internally I would prefer to use that for consistent slugs.
https://discord.com/channels/830184174198718474/1307294084045606953
Beta Was this translation helpful? Give feedback.
All reactions