I’m using an image lightbox plugin that requires some custom html tags that I would like to output in kirbytext. Tbh after searching the forum again I think I want to do exactly the same as this OP: Fancybox 3 in Kirby Text Field Hook?
So it looks like I have the choice between a hacky .gitignore file or using regex in a hook…
But with only these two “real” plugins, you might as well ignore them separately rather then the complete plugins folder? After all, it happens rather seldom that you don’t have any custom code in the plugins folder… (at least from my experience).
100% true. I initially thought of that but abandoned the thought because I might forget to add a future plugin to .gitignore after installing. But given the other options, this is definitely the easiest way :~)
edit: ok I see now that this has been talked about in the forum post I mentioned earlier. I’ll just read the docs again and will probably figure it out on my own
You can reuse parts as explained in the cookbook recipe, but in your case, it probably makes more sense to do a proper override… in any case, you can’t just call $file without defining that variable first!