Closed fwextensions closed 9 months ago
Thanks for this. Can confirm that this is a bug / change in behavior caused by the latest version of esbuild
. (The @create-figma-plugin/build
package has tests to verify that both export default
and module.exports
syntax both work out-of-the-box.)
Am considering pinning certain dependencies to exact versions… 🤔
I followed the instructions for adding an esbuild config file and used the code described there, but running a build with a
build-figma-plugin.main.js
file logs this error:I believe that this line is using
importFresh()
to import the config file. But that seems to assume it's requiring a CJS module, so I don't see how that could import an exported ES module. If it's assuming CJS, then the build error makes sense.