Getting Laravel-Sluggable to work with Spatie Laravel Tags #282
Replies: 1 comment
-
Hey! 👋 It sounds like you want to use the Laravel-Sluggable package with Spatie Laravel Tags to generate slugs for tags, but you're running into some issues due to limited documentation. Let’s go through a straightforward way to make them work together without needing to create a fully custom Step-by-Step Guide
Summary
This approach avoids modifying the original Spatie package and leverages Laravel-Sluggable to handle slugs automatically. Let me know if this helps or if you have any further questions! 😊 |
Beta Was this translation helpful? Give feedback.
-
Apologies for reposting this - I originally had it in Laravel Tags' discussion area but that appears to be a ghost town right now.
I've been having trouble getting routing via slug working with Laravel Tags. I haven't created a custom Tags model to add a Sluggable trait, which would probably work, but the Tags docs don't give a complete example and I'm not an advanced enough developer to fill in the missing pieces. I have a feeling that shouldn't be required as they're both packages by the same developer.
I see there's a config setting for choosing which slugger to use, but again the documentation stops before it spells out how to do it.
Beta Was this translation helpful? Give feedback.
All reactions