mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-12-20 09:20:16 +00:00
Disable caching for config.json file (#421)
* Disable caching for config.json file * Disable cache when fetching config.json
This commit is contained in:
@@ -80,7 +80,11 @@ if (process.env.NODE_ENV === "development") {
|
||||
|
||||
export async function initializeConfiguration(): Promise<ConfigContext> {
|
||||
try {
|
||||
const response = await fetch("./config.json");
|
||||
const response = await fetch("./config.json", {
|
||||
headers: {
|
||||
"If-None-Match": "", // disable client side cache
|
||||
},
|
||||
});
|
||||
if (response.status === 200) {
|
||||
try {
|
||||
const { allowedParentFrameOrigins, ...externalConfig } = await response.json();
|
||||
|
||||
Reference in New Issue
Block a user