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

[Work in Progress] Add Open Graph metadata tags to HackerWeb #59

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jabooth
Copy link

@jabooth jabooth commented Feb 24, 2017

Had a little hack this morning to try and add Open Graph tags to HackerWeb so that you would get rich previews when sharing hackerweb links with others (I often like to share the HW link rather than the original because HW is just such a cleaner experience to follow the comments!)

More on Open Graph: http://ogp.me/

Some guidance on integration: https://medium.com/@richardoosterhof/how-to-optimize-your-site-for-rich-previews-527ed13a6d69

This definitely isn't working correctly yet, but the gist is here. Not clear if I'll have time to finish refining this so instead of letting it bit rot I figured I'd at least show you what I have and see what you think.

Few thoughts:

  1. Do you get any kind of image URL from the HN API? If not we could just use a standard HW app image, or none at all.
  2. Likewise do you get a description from the API? I roughly propose here a generic statement, so that with the title a user seeing a rich link sees something like 'Find out what Hacker News thinks of this with HackerWeb.'

Any thoughts appreciated! And great work on HW BTW, use it every day and love it.

Issues:

1. Line endings to be fixed
2. Metadata not cleared on going back to main menu
3. Decide on what image to provide
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.

None yet

1 participant