Skip to content
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

Gracefully handle non-existant tags #147

Closed
nodunayo opened this issue Mar 25, 2019 · 5 comments
Closed

Gracefully handle non-existant tags #147

nodunayo opened this issue Mar 25, 2019 · 5 comments

Comments

@nodunayo
Copy link
Owner

You can see all proposals tagged with any given tag at: speakerline.io/tags/.

If you visit a page for a tag that doesn't yet exist, you will see the following page:

Screen Shot 2019-03-25 at 10 56 16

We need a more graceful way of handling this scenario.

Should the user be directed somewhere else or shown a custom error page?

@andrewmcodes
Copy link

I see two good options here:

  • Use redirect_back_or_to in the controller if the tag isn't found with the root as a fallback location and display a flash alert that the tag doesn't exist yet
    • Simpler option with less UX upside
  • Create an index page for tags and navigating to a non-existent show page will send you back to the index with a flash alert.
    • This one is slightly more work just because we'd have to come up with a tag index design
    • More UX upside than then first option because it may help them find the tag they are actually looking for or discover new ones.

WDYT?

@nodunayo
Copy link
Owner Author

Oh hi, @andrewmcodes! 👋🏾

I prefer the second one because of the discoverability aspect you mention! Right now, there's no way to see a complete list of the tags!

To start with the UI could be incredibly simple, i.e. exactly the same as the other list views, with the tag names in alphabetical order?

@hilarysk
Copy link
Contributor

hilarysk commented May 8, 2024

Working on this one at Hack Day for RailsConf 2024 :)

@nodunayo
Copy link
Owner Author

nodunayo commented May 8, 2024

@hilarysk Great stuff! Thank you!

Just one more addition: if someone attempts to just change the URL to a non-existent tag, we still get a 500. Can we handle that more gracefully? Perhaps with the redirect to the new wonderful index route?

Screenshot 2024-05-08 at 11 59 21

nodunayo added a commit that referenced this issue May 8, 2024
…andle-non-existent-tags

Issue #147 - Gracefully handle non-existent tags
@nodunayo
Copy link
Owner Author

nodunayo commented May 8, 2024

Note: This is going to be handled in PR #571 as that built on top of this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants