Replies: 2 comments 8 replies
-
I'm having difficulty understanding what is going on - can you explain what isn't working? Are you saying when you take the code above, put it in a file that gets included, everything but the image works? |
Beta Was this translation helpful? Give feedback.
-
Thanks Peter, An option for shortcodes like the getFilter would be nice. The named paramaters aren't a big deal. I was only using them since it makes it a little easier to remember what I'm passing into the shortcode. I'm going to give this a shot. If I can't make it work, then I'll probably just revert to using a CSS class for code reuse on the featured post and maintain the {% image %} shortcode for now. |
Beta Was this translation helpful? Give feedback.
-
I'm hoping that I'm missing something here. I've been struggling with figuring out how to make this piece of code reusable. It's a simple featured posts section using a shortcode for the 11ty image plugin.
My initial thought was to just create another shortcode, but this didn't work. So I tried a Nunjucks includes, but that wouldn't render the image shortcode.
Beta Was this translation helpful? Give feedback.
All reactions