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

Parse and publish hashtags in notes when posting #1693

Merged
merged 10 commits into from
Dec 10, 2024
Merged

Parse and publish hashtags in notes when posting #1693

merged 10 commits into from
Dec 10, 2024

Conversation

joshuatbrown
Copy link
Contributor

@joshuatbrown joshuatbrown commented Nov 18, 2024

Issues covered

https://github.com/verse-pbc/issues/issues/44

Description

Parses hashtags from posts and includes them as actual hashtags as defined in NIP-24.

How to test

  1. Tap the Post button
  2. Type some text with a hashtag (like #photography)
  3. Post the note
  4. Inspect the source for the note and find the t: photography in it.

Screenshots/Video

Screenshot 2024-11-18 at 2 32 13 PM

@joshuatbrown joshuatbrown requested a review from pelumy November 26, 2024 23:05
# Conflicts:
#	CHANGELOG.md
@mplorentz
Copy link
Member

👀

Copy link
Member

@mplorentz mplorentz left a comment

Choose a reason for hiding this comment

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

I love that we have this feature now! One request and one thought:

  • NIP-27 says that hashtags must be lowercased. I think if someone inputs #HaShTaG we need to add it to the tags as hashtag.
  • I'm not sure how hashtags work elsewhere, but I don't like that they are only terminated with whitespace or the end of the string. I expected punctuation to also terminate them. For example, I expected check out my #hashtag! to add the hashtag hashtag. I'm flexible on this one.

CHANGELOG.md Outdated Show resolved Hide resolved
@joshuatbrown
Copy link
Contributor Author

@mplorentz thanks for the request and thought! I've implemented both, so it's ready for another review.

Copy link
Member

@mplorentz mplorentz left a comment

Choose a reason for hiding this comment

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

Awesome, thanks!

@joshuatbrown joshuatbrown added this pull request to the merge queue Dec 10, 2024
Merged via the queue into main with commit ddbdb0c Dec 10, 2024
4 checks passed
@joshuatbrown joshuatbrown deleted the hashtags branch December 10, 2024 13:48
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.

2 participants