Closed dannystaple closed 1 year ago
Hello, I'm only on my phone at the moment, I will try to look at this later tonight.
In the meantime, here is my config,
https://github.com/vidhill/yan-static-site-experiment/blob/main/.eleventy.js
One thing worth checking is that in my example, I was using nunjucks templates, I wonder if the syntax for shortcodes is different for liquid templates? Perhaps?
Ok - I found it. And feel a bit dumb. It should've been in quotes, otherwise it's looking for a liquid variable (or whatever it calls them). Annoyingly, unset variables are simply ignored or "".
Ah, glad you got sorted
I'm somewhat new to 11ty (having come from the Jekyll ssg), and I'm having difficulty with this plugin. I've installed the tool as a dev dependency
npm install --save-dev @vidhill/fortawesome-brands-11ty-shortcode
- matching most of the other 11ty tools I have installed. In the top of the .eleventy.js file I've imported it:And in the settings:
I test this with a command
npm run serve
, in my package.json that is:When I then inspect the page, at the intended
.list-group-item
element I see nothing there at all:I've tried to see if it would generate an issue if I suggest a non-existent icon:
Nothing happened - no change here. I used console.log with the fortawesomeBrandsPlugin variable, and see that it is a function. I'd love any help you have on this one, as it beats what my live site is doing - loading the whole font-awesome css for 4 icons. 🤦