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 recipe for using getImage() and creating custom component #5042
Add recipe for using getImage() and creating custom component #5042
Conversation
✅ Deploy Preview for astro-docs-2 ready!Built without sensitive environment variables
To edit notification comments on pull requests, go to your Netlify site configuration. |
Thank you for jumping on this issue, @jdwilkin4 ! 🙌 As luck would have it, Astro is finally releasing its own experimental Picture component and So, I think this could be a great addition if we can frame it as something more than "creating a Picture component" (because tomorrow, we'll have an implementation of that), but maybe referring specifically to the media query/art direction aspect of it, since ours will not support that? Right now, it's a perfectly functional recipe, but it's lacking a bit of a "story" around it that it could use now that we have a Picture component. I think this works if we make it clear that it's even going beyond the existing Picture component, and that It might be useful to look at the PR we have that will be released tomorrow, showing what our Picture component will do (and, you'll see that it won't support setting a And, I also wanted to point out that we have a So take a look at the Picture component coming out, what it will/won't do, and see if you can add some "when/why would I use this?" context to this recipe. Also, we shouldn't title the file And I can see Erika has left some technical suggestions, so I'll let you address those and then think about the story you want to tell around this! Let me know if you have any questions, but I think using the |
Hi @sarah11918 ! Thank you for your comment and notes. |
Hi @sarah11918 ! I have updated the recipe 👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @jdwilkin4 this looks great! I can really tell that you ran with the narrative concept successfully and that makes this super helpful and useful to people! 🙌
I left some editing suggestions with my thoughts as I went through it, so see what you think. Looking forward to having this as an official recipe in docs!
@jdwilkin4 Jessica, I am so happy with how this turned out, and I hope you are, too! We really appreciate you seeing an issue you can tackle, and taking the initiative to contribute. I don't think we've had a new official recipe in a while, and this will be very helpful to our community. Thank you again! |
The new recipe looks great 😀 |
Description (required)
This PR is responsible for creating a recipe for how to use the getImage function in a custom picture component.
I have linked to the new recipe in the Generating images with getImage() section of the images guide
I am participating in hacktoberfest. Please add the hacktoberfest-accepted if this issue is accepted. Thank you 👍
Related issues & labels (optional)
getImage()
helper to create your own Picture component, or use scrset etc. #4389Links to pages changed