-
Notifications
You must be signed in to change notification settings - Fork 43
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
Eleventy (11ty) Shortcode #624
Comments
That sounds like a good idea. If you'd be up for implementing it I'd be happy to add it. I'd make it a new package, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is your feature request related to a problem? Please describe.
As an Eleventy (11ty) user, I struggle to integrate the existing WebC image component provided by unpic-img. While WebC works well for some projects, not everyone using Eleventy relies on it. Eleventy shortcodes (https://www.11ty.dev/docs/shortcodes/) are very flexible and they can be used in Nunjucks, Liquid, JavaScript, languages used by most of the people that are using Eleventy.
Describe the solution you'd like
I propose adding a new Eleventy shortcode. This shortcode would allow users to easily embed responsive images using the unpic-img library within their Eleventy templates and pages, to "generates a responsive tag that follows best practices, with the correct srcset, sizes and styles; detect image URLs from most image CDNs and CMSs and can resize images with no build step." (taken from the @unpic/webc docs).
Describe alternatives you've considered
Creating my own 11ty shortcode for integrating Unpic, but I think a built-in shortcode that comes with the library, or at least an "official" example of how to implement it would be great.
Additional context
I guess the unpic-img.webc file should be translated to an 11ty shortcode?
Thank you
The text was updated successfully, but these errors were encountered: