Open sapphi-red opened 1 year ago
Seems that this.info
wouldn't be called by rollup itself until the plugins call it
Hello!
When I use some rollup plugins, only warning log at the plugin for rollup is treated by the vite.
I propose the following three modifications.
Use onLog
instead of onwarn
. (Rollup Configuration guide - onLog)
Following codes would be modified to accept all log levels(info,warn,error,debug). https://github.com/vitejs/vite/blob/6d5be5c6c9547745d3cedef1ff1295be78c09193/packages/vite/src/node/build.ts#L869-L936
Also change the options where Rollup is called in different code.
Thank you!
+1
Seems onwarn and onLog defined in vite.config.mts are not called when running npx vite build
Description
Rollup added logging functions (
this.info
,this.debug
) in 3.25.0. Currently we added them as a no-op in #13608. But we should output logs.Suggested solution
Implement them. I guess we would call
config.logger.info
forthis.info()
. I don't know what we should do forthis.debug()
.Also I guess we should pass
logLevel
to Rollup.Alternative
No response
Additional context
No response
Validations