teamable-software/css-chunks-html-webpack-plugin

How do I get the initial load working?

sontek opened this issue · 2 comments

This async fetches the CSS if the page isn't the first page load. But it doesn't load the asset if its the first page. So you have to visit a different page and then go back to see the styles.

It was injecting into the body no matter what (I had inject: head). Once I put it in manually it all worked.

@sontek sorry for the late response. The injection target was defined by the option in HtmlWebpackPlugin, not this one. However, you are right, that was confusing. I've changed the default injection target to <head> and add the ability to set the injection target in this plugin.