- Filename tells the plugin what we want to name the copied file (in this case it’s the same), and then inject tells the plugin where we want the bundled JS file to be injected inside the copied index.html file (in this case we want it right before the closing tag).
- Sorry, your blog cannot share posts by email.
- The plugin allows us to make a copy of our index.html within our ‘app’ directory, output that copy into the ‘dist’ directory, AND have that new bundled JS file referenced from within that index.html copy.
- The transformations that need to be done to the code.
Read the full article, click here.
Do you find webpack super confusing and hard to understand? In this post, njosefbeck explores a simple webpack config file to share what he’s learned.
Simple Webpack Config Walkthrough