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

Reduce image size for banned cards #172

Open
shenef opened this issue Aug 17, 2020 · 3 comments
Open

Reduce image size for banned cards #172

shenef opened this issue Aug 17, 2020 · 3 comments

Comments

@shenef
Copy link

shenef commented Aug 17, 2020

Currently the website seems to load the biggest PNG scryfall offers which causes the site to download about 17 MB of data on the first load.
Scryfall also offers large JPG files with a size of 100-200 kB each: https://scryfall.com/docs/api/images
That should dramatically cut down on load times (which can be a minute and up on mobile) and RAM usage.

@glacials
Copy link
Owner

👍 Agree, would accept a PR!

@tooomm
Copy link
Contributor

tooomm commented Jan 20, 2021

It looks like currently the "large" jpg's are used on the webpage - not the png's anymore.
They have still a unreasonable huge resolution and I can watch them loading...

Edit: That's not the case for all of them. Looks like the large jpg's are a fallback if there is no png available (e.g. "Escape to the Wilds" links to https://c1.scryfall.com/file/scryfall-cards/large/front/3/e/3e26c10b-179f-4a6e-bc8d-3ec1d6783fb9.jpg?1602499769)

Why not use the "normal" sized jpg's for displaying on the webpage? 488 × 680 is still big and should be sufficient there.

@glacials
Copy link
Owner

See #173

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 a pull request may close this issue.

3 participants