An open API service indexing awesome lists of open source software.

https://github.com/sqlwwx/reload-latest-webpack-plugin


https://github.com/sqlwwx/reload-latest-webpack-plugin

Last synced: about 1 year ago
JSON representation

Awesome Lists containing this project

README

          

# reload-latest-webpack-plugin

## Installation
```
npm install reload-latest-webpack-plugin
```
## Usage
```
var ReloadLatestHash = require('reload-latest-webpack-plugin');
var webpackConfig = {
plugins: [new ReloadLatestHash()]
};
```
```



Webpack App



window.hash = '<%= webpack.hash %>'
var script = document.createElement('SCRIPT')
script.setAttribute('src', '/reload-latest-hash.js?version=' + (Date.now() + '').substr(0, 7))
document.head.insertBefore(script,document.head.firstChild);



```