browser-sync-webpack-plugin
browser-sync-webpack-plugin copied to clipboard
Use the compilation trigger to determine whether CSS injection should happen instead of emitted asset names.
Per discussion on #78 , I've created this. It might be worth deleting lib/getCssOnlyEmittedAssetsNames.js since I've removed the one call to it's method, but I wasn't sure if that was my place on this adjustment.
I also created an option that defaults to scss/sass/less/css as the regular expression for comparison against the compilation trigger.
It looks like this PR might resolve issues in #69 and #70 as well.
Tested and works. My setup uses mini-css-extract-plugin that extracts css.
I cannot seem to get this working. Can you please share your config?
@Brendonwbrown It might be better to see an example of where it isn't working for you.
@Va1 any thoughts on this? =)
any updates?
can someone verify this works and, if it does, that it does on all webpack major versions available?