Webpack & CSS - 2. Loaders and HMR

preview_player
Показать описание
Setting up our loaders and HMR so that we can import and run our CSS through Webpack for development

Рекомендации по теме
Комментарии
Автор

i prefer type and comments :D, but this is awesome, thanks for share!!!

kevgi
Автор

I thought that webpack needs an extract plugin for putting the styles link in the head section of html. And indeed it unfortunately doesn't show up in my index.html in the build. I've copied the code 1:1 and I still end up with just the script tag in the index.html. No link to stylesheet. Would You have any idea why it differs for me?

mateuszmysiak
Автор

Great videos.

For some reason when I add "hot: true" the page no longer even updates the "index.html" file. In the terminal it shows that it's compiling though. I've troubleshooted down to that singular line of code. I've also tried "webpack-dev-server --hot" but that has the same problem. Any ideas?

On a side note, the css has never been successful loading. I've added the loader and the plugin as shown in the video.

DavidHust