-
I'm trying to move several related filters into a plugin that I plan to publish as an npm module. While I'm developing it, I'm loading it as a custom plugin in ./plugins/game. The filters are in ./plugins/game/index.js and everything works. But every plugin I've looked at uses .eleventy.js. If I put my filters in ./plugins/game/eleventy.js, 11ty throws an error: "Cannot find module './plugins/game'. Is that because it's a custom plugin? IOW, if my plugin were installed in ./node-modules/, could I then use .eleventy.js as other plugins do? And is there a guide for making plugins? The only one I've found so far is https://bryanlrobinson.com/blog/creating-11ty-plugin-embed-svg-contents/, which hasn't given me as much guidance as I apparently need. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Amateur error: I was missing package.json with the |
Beta Was this translation helpful? Give feedback.
Amateur error: I was missing package.json with the
main
key.