Skip to content

Conversation

@joshreisner
Copy link
Contributor

@joshreisner joshreisner commented Oct 12, 2025

this PR adds a new data-path param to the TSML UI embed code that will enable support for "pretty" permalinks.

for example, take the current meeting URL /meetings?meeting=serenity-sunday

if data-path="/meetings" then the URL will be /meetings/serenity-sunday

if data-path is not specified, then the URL will be /meetings#/serenity-sunday

if you land on a legacy URL, you will be redirected to one of the above

(TSML will need a small PR to add support for this param)

closes #357

@joshreisner joshreisner self-assigned this Oct 12, 2025
@joshreisner joshreisner linked an issue Oct 12, 2025 that may be closed by this pull request
@netlify
Copy link

netlify bot commented Oct 12, 2025

Deploy Preview for tsml-ui ready!

Name Link
🔨 Latest commit 9d0374e
🔍 Latest deploy log https://app.netlify.com/projects/tsml-ui/deploys/68ec39c14830b80008cef88e
😎 Deploy Preview https://deploy-preview-475--tsml-ui.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link
Collaborator

@pjaudiomv pjaudiomv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks great! The implementation is well done. I'm guessing the tests are currently failing because the Meeting component now uses useParams() to get the slug from the URL instead of receiving it as a prop

@pjaudiomv
Copy link
Collaborator

im guessing you would only use data-path for wordpress or when you have server side rewrite rules, may want to state that in tsml ui docs that the attribute isnt needed or shouldnt be used if using client side

@joshreisner
Copy link
Contributor Author

@pjaudiomv good callout about the documentation - i added a note about when to add data-path manually.

@joshreisner joshreisner merged commit 2cdeaff into main Oct 13, 2025
5 of 6 checks passed
@joshreisner joshreisner deleted the 357-pretty-permalink-urls-using-react-router-2 branch October 13, 2025 03:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

"Pretty" permalink URLs using React Router

3 participants