Skip to content

Commit

Permalink
Fix frontend not loading after update. Koenkk#4266
Browse files Browse the repository at this point in the history
  • Loading branch information
Koenkk committed Oct 11, 2020
1 parent 9098bb1 commit 73bc34f
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lib/extension/frontend.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,13 @@ class Frontend extends Extension {
if (this.development) {
this.proxy = httpProxy.createProxyServer({ws: true});
} else {
this.fileServer = serveStatic(frontend.getPath());
/* istanbul ignore next */
const options = {setHeaders: (res, path) => {
if (path.endsWith('index.html')) {
res.setHeader('Cache-Control', 'no-store');
}
}};
this.fileServer = serveStatic(frontend.getPath(), options);
}

this.wss = new WebSocket.Server({noServer: true});
Expand Down

0 comments on commit 73bc34f

Please sign in to comment.