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

add: client-side thumbnail fetching from websites with CORS access #386

Closed
plebeius-eth opened this issue Oct 11, 2024 · 2 comments
Closed
Assignees
Labels
enhancement New feature or request

Comments

@plebeius-eth
Copy link
Member

A user reported a missing thumbnail from a link to his website, which has CORS access: https://pleb.bz/p/plebpiracy.eth/c/QmSTx9pX1Ttk5tKfs6EJQk5sonXckjNwF2srBbhFHPKKKv

most sites don't have CORS access because it's a security risk, but it's cool to enable client-side thumbnail fetching for those who do I guess. Subplebbits have thumbnail fetching turned off by default because it leaks the plebbit node IP address.

@plebeius-eth
Copy link
Member Author

b3bbb9c

@github-project-automation github-project-automation bot moved this from In Progress to Done in seedit Oct 12, 2024
@estebanabaroa
Copy link
Member

we use this library for getting the thumbnail in the subplebbit, dont think it works in the browser but there might be other fallbacks than just doing const ogImage = doc.querySelector('meta[property="og:image"]');

https://www.npmjs.com/package/open-graph-scraper
https://github.com/jshemas/openGraphScraper/blob/master/lib/extract.ts

not super high priority but something to think about

@plebeius-eth plebeius-eth removed this from seedit Oct 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants