-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: allow special characters to pass through slugification #6220
base: main
Are you sure you want to change the base?
Conversation
@erezrokah Hey, is this solution acceptable? Should I go ahead and update the tests? |
Sorry @mikestopcontinues, haven't been able to dig into this. |
456bd25
to
d9560f4
Compare
Hi @erezrokah thanks. I was waaay off! I updated the PR to specifically target preview paths, under two conditions:
(2) is because my use-case is a You can see both the nested-method and the slug-method at work in the dev Two questions:
|
Hi @mikestopcontinues, I completely forgot we did #4279 a while back to support the use case described in the issue. Can you try using |
Hi @erezrokah
slug: {{fields.slug}}
preview_path: /{{fields.slug}} And |
@erezrokah Sorry to ping you on this, but it's a blocker for my current site upgrade. Any thoughts? |
Sorry for the delay @mikestopcontinues. I might not be able to look at this for another week.
If this is blocking you should be able to use the generated CMS build from this Deploy Preview, |
@erezrokah Thanks! For the time being, I'll try the deploy preview. Let me know what I can do to officially move this forward when you can. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
@mikestopcontinues are you still interested in moving this forward? |
Sorry @martinjagodic, I no longer use Decap. |
Summary
Some of us would like to include
/
in our slug fields to build nested page structures. This PR allows arbitrary chars to pass through slugification, above and beyond what's allowed byslug.encoding
. Useful for/
and perhaps for other functionality in future.Fixes #4963
Test plan
I added new tests for the new parameter I added demonstrating the
true
andfalse
case. I also updated the devconfig.yml
with two example collections.Checklist
Please add a
x
inside each checkbox:yarn format
.yarn test
.A picture of a cute animal (not mandatory but encouraged)