This repository has been archived by the owner on Aug 4, 2021. It is now read-only.
Warnings don't work with Rollup's onwarn
function
#84
Labels
onwarn
function
#84
With version
2.6.1
ofrollup-plugin-babel
I am getting these errors in the console:I have investigated the bundle and I know exactly why it is warning: I am importing a file in
node_modules
which has been pre-transpiled, so it is using ES6 modules but ES5 syntax, therefore it includes its own internal version ofcreateClass
andclassCallCheck
. From what I understand, this is exactly what package authors are supposed to do.Ideally
rollup-plugin-babel
would be smart enough to figure out that this is okay, but in the meantime I would really like to silence these warnings.So I tried defining an
onwarn
function in myrollup.config.js
:This works fine for warnings generated by Rollup itself, but does not work for the warnings generated by
rollup-plugin-babel
(such as the above).The text was updated successfully, but these errors were encountered: