Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

html-webpack-live-reload-plugin

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

html-webpack-live-reload-plugin

Reloads browser when watching any assets changes, friends with html-webpack-plugin / webpack5

  • 1.0.12
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

html-webpack-live-reload-plugin

Reloads browser when watching any assets changes, friends with html-webpack-plugin / webpack5

This intentionally works with the last webpack 5, html-webpack-plugin inject html with assets feature

Usage

webpack.config.js

const HtmlWebpackLiveReload = require('html-webpack-live-reload-plugin');

plugins: [
    new HtmlWebpackPlugin() // intentionally work together with this
    new HtmlWebpackLiveReload(),
  ]

The plugin will start only when "watch" mode

API

new HtmlWebpackLiveReload(options)

  • options.port: socket server port, default 3333

Need to Know

HtmlWebpackLiveReload does only watch live reload via standalone socket.io

  • It has to another web server to handle http(s)
  • The standalone socket.io has different web origin. Most of browser block this working. The worth case, the live reload stopped.
  • To overcome this, "Moesif Origin" browser extension is the easiest. I do not want to anything extra in production code. So, developer do one more thing, please

The End

Simple and do the work for me. Thanks.

Keywords

FAQs

Package last updated on 10 Sep 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc