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

FEATURE: Add way to automatically resize/optimize photos #18

Closed
KyleAMathews opened this issue Aug 6, 2015 · 6 comments
Closed

FEATURE: Add way to automatically resize/optimize photos #18

KyleAMathews opened this issue Aug 6, 2015 · 6 comments

Comments

@KyleAMathews
Copy link
Contributor

When copying assets to the public folder, optimize images.

@KyleAMathews
Copy link
Contributor Author

@KyleAMathews KyleAMathews changed the title auto-optimize images etc. Add image loader w/ optimized production build Feb 26, 2016
@KyleAMathews KyleAMathews changed the title Add image loader w/ optimized production build FEATURE: Add image loader w/ optimized production build Feb 26, 2016
@pamo
Copy link
Contributor

pamo commented Mar 13, 2016

I actually have this on my to-do list but after some consideration and poking around, I realized webpack configuration would be a round-about way to do it.

Images aren't imported as modules when they're inlined in markdown so webpack doesn't really see them. I'm thinking a markdown-it plugin may be the easiest way.

@KyleAMathews
Copy link
Contributor Author

@pamo yeah the image optimization only happens if you require an image which is only a sub-set of the images you have on your site and wouldn't include images that are part of a blog like yours.

I'd like something where I could drop and image in a folder and when copying it'd to /public it'd resize + optimize the photo size.

I'll change the title to make more clear what this issue is about.

@KyleAMathews KyleAMathews changed the title FEATURE: Add image loader w/ optimized production build FEATURE: Add way to automatically resize/optimize photos Mar 13, 2016
@pamo
Copy link
Contributor

pamo commented Mar 13, 2016

That'd be the best solution. My google-fu was waning yesterday but I'm sure there's something that is capable of it.

@KyleAMathews
Copy link
Contributor Author

Probably this isn't something that should be built into gatsby but that
gatsby provides the hooks to build this in user land.
On Sun, Mar 13, 2016 at 10:18 AM Pamela Ocampo [email protected]
wrote:

That'd be the best solution. My google-fu was waning yesterday but I'm
sure there's something that is capable of it.


Reply to this email directly or view it on GitHub
#18 (comment).

@KyleAMathews
Copy link
Contributor Author

Shipped solution to this in 0.12 https://github.com/gatsbyjs/gatsby/releases/tag/v0.12.0

pragmaticpat pushed a commit to pragmaticpat/gatsby that referenced this issue Apr 28, 2022
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

No branches or pull requests

2 participants