html-critical-webpack-plugin icon indicating copy to clipboard operation
html-critical-webpack-plugin copied to clipboard

Inline bootstrap

Open ZeroTworu opened this issue 6 years ago • 1 comments

How can i define special CSS rules to inline into html? Problem: I using bootstrap and this plugin, but plugin inline only part of bootstrap css (buttons dont inline), so i see sam "lag" after page loading, In first loading "base" browser buttons, and then after ~0.5s loaded normal buttons.

ZeroTworu avatar Sep 27 '18 02:09 ZeroTworu

this plugin doesn't really do much other than just provide a wrapper around critical itself, so the best bet would be to look up what the options are available in the critical API and try that out with this plugin.

AFAIK, critical depends on a index.html that it can process to try and find what those critical styles are so it can inline them. Maybe some of your code is async and not getting "picked up" by critical? There could be other reasons, based on the structure / build of your code.

thescientist13 avatar Sep 30 '18 21:09 thescientist13