Describe the solution you'd like
Right now webpackConfigHook only receives the current webpack config, which means if we need to use things like DefinePlugin, the caller has to import webpack directly. This may cause issues as the caller may wrongly use a webpack version different from the one used by @temporalio/worker.
Ideally, we can do something like this:
webpackConfigHook(config, webpack) {
// ... do something with webpack, such as
config.plugins.push(
new webpack.DefinePlugin({
'someValue': {},
})
)
return config
}