Compare commits

...

1 commit

Author SHA1 Message Date
Alec Armbruster
c17e1375b3
fix dev env caching 2023-06-29 16:27:28 -04:00
2 changed files with 6 additions and 1 deletions

View file

@ -8,7 +8,7 @@
"scripts": {
"analyze": "webpack --mode=none",
"prebuild:dev": "yarn clean && node generate_translations.js",
"build:dev": "webpack --env COMMIT_HASH=$(git rev-parse --short HEAD) --mode=development",
"build:dev": "webpack --env COMMIT_HASH=$(git rev-parse --short HEAD) NODE_ENV=development --mode=development",
"prebuild:prod": "yarn clean && node generate_translations.js",
"build:prod": "webpack --env COMMIT_HASH=$(git rev-parse --short HEAD) --mode=production",
"clean": "yarn run rimraf dist",

View file

@ -27,6 +27,11 @@ export function setCacheControl(
res: Response,
next: NextFunction
) {
// Avoid setting Cache-Control in development
if (process.env.NODE_ENV === "development") {
return next();
}
const user = UserService.Instance;
let caching: string;