Closed
Description
We're using mini-css-extract-plugin
to generate a CSS entry point that we're dynamically appending to the contents of an <iframe>
at runtime.
To enable long-term-caching, we'd love to add a content hash to the resulting .css
file. This works great and is documented here.
However, since we're manually loading the CSS at runtime, we'll need a way to access the resulting chunk filename there as well. I can only seem to find solutions which will emit the mapping as an external file. Solutions like the file-loader will allow access to the resulting chunk name at runtime - something like this would be ideal for our use case.
What's the best-practice solution to dynamically load the generated CSS file in our use case?