While Twigpack has been great for development, I suspect we'll need to remove the composer dependency and reliance in production mode as it's unreasonable to force users to have the plugin installed just to use our plugin.
As we're publishing the dist assets via a Yii Asset Bundle which has it's own form of cache busting, we can configure Webpack to spit out a non-hashed filename during a production build and load that file via the Asset Bundle.
While Twigpack has been great for development, I suspect we'll need to remove the composer dependency and reliance in production mode as it's unreasonable to force users to have the plugin installed just to use our plugin.
As we're publishing the dist assets via a Yii Asset Bundle which has it's own form of cache busting, we can configure Webpack to spit out a non-hashed filename during a production build and load that file via the Asset Bundle.