Closed josdejong closed 2 months ago
Sure @josdejong, do you want to make a PR for it and I'll run it by @epoberezkin ?
Definitely! Here you go: #2480
Merged. Not sure when it will go out, but I'll keep you posted.
Thanks Jason 👍
Any news on this @jasoniangreen? A bug fix release would be very welcome 😅
I have a library that amongst others exports a utility function
createAjvValidator
that usesajv
. Now, not all users of my library use this utility function, but I noticed that the Ajv library is always included when creating a js bundle containing my library, also when the ajv utility function is not used at all. It turns out that tree-shaking is not working.Can the flag
"sideEffects": false
be added to thepackage.json
file ofajv
? That will enable tree shaking by Vite/Rollup/Webpack out of the box.See: