mirror of https://github.com/grpc/grpc-web.git
Disable caching of local generated main.js file (#1193)
This commit is contained in:
parent
eb313c1f3d
commit
4dbd519bc8
|
|
@ -19,7 +19,12 @@
|
|||
<title>Echo Example</title>
|
||||
<link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
|
||||
<script src="//ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
|
||||
<script src="./dist/main.js"></script>
|
||||
<script>
|
||||
// Load the local /dist/main.js and use a random query parameter to disable caching.
|
||||
const script = document.createElement('script');
|
||||
script.src = `./dist/main.js?v=${Date.now()}`;
|
||||
document.head.appendChild(script);
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
|
|
|
|||
|
|
@ -19,7 +19,12 @@
|
|||
<title>Echo Example</title>
|
||||
<link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
|
||||
<script src="//ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
|
||||
<script src="./dist/main.js"></script>
|
||||
<script>
|
||||
// Load the local /dist/main.js and use a random query parameter to disable caching.
|
||||
const script = document.createElement('script');
|
||||
script.src = `./dist/main.js?v=${Date.now()}`;
|
||||
document.head.appendChild(script);
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
|
|
|
|||
Loading…
Reference in New Issue