Register a callback which will be invoked when bundling starts. When using hot module reloading, this is called at the start of each incremental rebuild.
Symbol
PluginBuilder.onStart
@returns
this
for method chaining
Bun.plugin({
setup(builder) {
builder.onStart(() => {
console.log("bundle just started!!")
});
},
});
Referenced types
type OnStartCallback = () => void | Promise<void>