Explorar o código

Merge pull request #16524 from overleaf/em-fix-typescript-backend

Fix typescript config in the backend

GitOrigin-RevId: fb292968bc14da6d7c17bee1da00803a74901899
Eric Mc Sween %!s(int64=2) %!d(string=hai) anos
pai
achega
b92d1a0251
Modificáronse 50 ficheiros con 324 adicións e 180 borrados
  1. 5 4
      libraries/access-token-encryptor/package.json
  2. 4 0
      libraries/access-token-encryptor/tsconfig.json
  3. 5 4
      libraries/fetch-utils/package.json
  4. 4 0
      libraries/fetch-utils/tsconfig.json
  5. 5 4
      libraries/logger/package.json
  6. 4 0
      libraries/logger/tsconfig.json
  7. 5 4
      libraries/metrics/package.json
  8. 4 0
      libraries/metrics/tsconfig.json
  9. 0 83
      libraries/o-error/index.d.ts
  10. 6 8
      libraries/o-error/package.json
  11. 4 0
      libraries/o-error/tsconfig.json
  12. 5 4
      libraries/object-persistor/package.json
  13. 4 0
      libraries/object-persistor/tsconfig.json
  14. 5 4
      libraries/overleaf-editor-core/package.json
  15. 4 0
      libraries/overleaf-editor-core/tsconfig.json
  16. 5 3
      libraries/promise-utils/package.json
  17. 4 0
      libraries/promise-utils/tsconfig.json
  18. 4 3
      libraries/ranges-tracker/package.json
  19. 4 0
      libraries/ranges-tracker/tsconfig.json
  20. 5 3
      libraries/redis-wrapper/package.json
  21. 4 0
      libraries/redis-wrapper/tsconfig.json
  22. 6 3
      libraries/settings/package.json
  23. 4 0
      libraries/settings/tsconfig.json
  24. 5 4
      libraries/stream-utils/package.json
  25. 4 0
      libraries/stream-utils/tsconfig.json
  26. 17 3
      services/chat/Makefile
  27. 1 1
      services/chat/package.json
  28. 17 3
      services/clsi/Makefile
  29. 2 1
      services/clsi/package.json
  30. 17 3
      services/contacts/Makefile
  31. 2 1
      services/contacts/package.json
  32. 17 3
      services/docstore/Makefile
  33. 2 1
      services/docstore/package.json
  34. 17 3
      services/document-updater/Makefile
  35. 2 1
      services/document-updater/package.json
  36. 17 3
      services/filestore/Makefile
  37. 2 1
      services/filestore/package.json
  38. 17 3
      services/history-v1/Makefile
  39. 2 1
      services/history-v1/package.json
  40. 17 3
      services/notifications/Makefile
  41. 2 1
      services/notifications/package.json
  42. 17 3
      services/project-history/Makefile
  43. 2 1
      services/project-history/package.json
  44. 17 3
      services/real-time/Makefile
  45. 2 1
      services/real-time/package.json
  46. 1 1
      services/spelling/.nvmrc
  47. 18 4
      services/spelling/Makefile
  48. 1 1
      services/spelling/buildscript.txt
  49. 2 1
      services/spelling/package.json
  50. 4 2
      services/web/Dockerfile

+ 5 - 4
libraries/access-token-encryptor/package.json

@@ -3,17 +3,18 @@
   "version": "3.0.0",
   "description": "",
   "main": "index.js",
-  "types": "./types/index.js",
+  "types": "./types/index.d.ts",
   "scripts": {
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "lint": "eslint --ext .js --ext .cjs --max-warnings 0 --format unix .",
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "author": "",
   "license": "AGPL-3.0-only",

+ 4 - 0
libraries/access-token-encryptor/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 5 - 4
libraries/fetch-utils/package.json

@@ -3,17 +3,18 @@
   "version": "0.1.0",
   "description": "utilities for node-fetch",
   "main": "index.js",
-  "types": "types/index.js",
+  "types": "types/index.d.ts",
   "scripts": {
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "lint": "eslint --ext .js --ext .cjs --max-warnings 0 --format unix .",
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "author": "Overleaf (https://www.overleaf.com)",
   "license": "AGPL-3.0-only",

+ 4 - 0
libraries/fetch-utils/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 5 - 4
libraries/logger/package.json

@@ -7,19 +7,20 @@
     "url": "https://github.com/overleaf/overleaf"
   },
   "main": "index.js",
-  "types": "types/index.js",
+  "types": "types/index.d.ts",
   "license": "AGPL-3.0-only",
   "version": "3.1.1",
   "scripts": {
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
     "lint": "eslint --ext .js --ext .cjs --max-warnings 0 --format unix .",
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "dependencies": {
     "@google-cloud/logging-bunyan": "^5.0.0",

+ 4 - 0
libraries/logger/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 5 - 4
libraries/metrics/package.json

@@ -7,7 +7,7 @@
     "url": "https://github.com/overleaf/metrics-module.git"
   },
   "main": "index.js",
-  "types": "types/index.js",
+  "types": "types/index.d.ts",
   "dependencies": {
     "@google-cloud/opentelemetry-cloud-trace-exporter": "^2.1.0",
     "@google-cloud/profiler": "^6.0.0",
@@ -34,12 +34,13 @@
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
     "test:acceptance": "mocha --reporter spec --recursive --exit --grep=$MOCHA_GREP test/acceptance",
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "peerDependencies": {
     "@overleaf/logger": "*"

+ 4 - 0
libraries/metrics/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 0 - 83
libraries/o-error/index.d.ts

@@ -1,83 +0,0 @@
-export = OError;
-/**
- * Light-weight helpers for handling JavaScript Errors in node.js and the
- * browser.
- */
-declare class OError extends Error {
-    /**
-     * @param {string} message as for built-in Error
-     * @param {Object} [info] extra data to attach to the error
-     * @param {Error} [cause] the internal error that caused this error
-     */
-    constructor(message: string, info?: any, cause?: Error);
-    info: any;
-    cause: Error;
-    /** @private @type {Array<TaggedError> | undefined} */
-    private _oErrorTags;
-    /**
-     * Set the extra info object for this error.
-     *
-     * @param {Object} info extra data to attach to the error
-     * @return {this}
-     */
-    withInfo(info: any): OError;
-    /**
-     * Wrap the given error, which caused this error.
-     *
-     * @param {Error} cause the internal error that caused this error
-     * @return {this}
-     */
-    withCause(cause: Error): OError;
-}
-declare namespace OError {
-    /**
-     * Tag debugging information onto any error (whether an OError or not) and
-     * return it.
-     *
-     * @example <caption>An error in a callback</caption>
-     * function findUser(name, callback) {
-     *   fs.readFile('/etc/passwd', (err, data) => {
-     *     if (err) return callback(OError.tag(err, 'failed to read passwd'))
-     *     // ...
-     *   })
-     * }
-     *
-     * @example <caption>A possible error in a callback</caption>
-     * function cleanup(callback) {
-     *   fs.unlink('/tmp/scratch', (err) => callback(err && OError.tag(err)))
-     * }
-     *
-     * @example <caption>An error with async/await</caption>
-     * async function cleanup() {
-     *   try {
-     *     await fs.promises.unlink('/tmp/scratch')
-     *   } catch (err) {
-     *     throw OError.tag(err, 'failed to remove scratch file')
-     *   }
-     * }
-     *
-     * @param {Error} error the error to tag
-     * @param {string} [message] message with which to tag `error`
-     * @param {Object} [info] extra data with wich to tag `error`
-     * @return {Error} the modified `error` argument
-     */
-    export function tag(error: Error, message?: string, info?: any): Error;
-    /**
-     * The merged info from any `tag`s and causes on the given error.
-     *
-     * If an info property is repeated, the last one wins.
-     *
-     * @param {Error | null | undefined} error any error (may or may not be an `OError`)
-     * @return {Object}
-     */
-    export function getFullInfo(error: Error): any;
-    /**
-     * Return the `stack` property from `error`, including the `stack`s for any
-     * tagged errors added with `OError.tag` and for any `cause`s.
-     *
-     * @param {Error | null | undefined} error any error (may or may not be an `OError`)
-     * @return {string}
-     */
-    export function getFullStack(error: Error): string;
-    export const maxTags: Number;
-}

+ 6 - 8
libraries/o-error/package.json

@@ -13,26 +13,24 @@
     "verror"
   ],
   "main": "index.cjs",
-  "types": "types/index.cjs",
+  "types": "types/index.d.cts",
   "files": [
     "index.cjs",
     "index.d.ts"
   ],
   "scripts": {
-    "build": "npm run --silent typecheck && npm run --silent test && npm run --silent declaration:build && npm run --silent update-readme",
-    "declaration:build": "rm -f index.d.ts && tsc --allowJs --declaration --emitDeclarationOnly --moduleResolution node --target ES6 index.js",
-    "declaration:check": "git diff --exit-code -- index.d.ts",
+    "build": "npm run --silent test && npm run --silent update-readme",
     "lint": "eslint --ext .js --ext .cjs --max-warnings 0 --format unix .",
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
-    "prepublishOnly": "npm run --silent declaration:build && npm run --silent declaration:check",
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
-    "typecheck": "tsc --noEmit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "update-readme": "doc/update-readme.js",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
     "test:ci": "npm run test:unit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "author": "Overleaf (https://www.overleaf.com)",
   "license": "MIT",

+ 4 - 0
libraries/o-error/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 5 - 4
libraries/object-persistor/package.json

@@ -3,17 +3,18 @@
   "version": "1.0.2",
   "description": "Module for storing objects in multiple backends, with fallback on 404 to assist migration between them",
   "main": "index.js",
-  "types": "types/index.js",
+  "types": "types/index.d.ts",
   "scripts": {
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
     "lint": "eslint --ext .js --ext .cjs --max-warnings 0 --format unix .",
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "repository": {
     "type": "git",

+ 4 - 0
libraries/object-persistor/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 5 - 4
libraries/overleaf-editor-core/package.json

@@ -3,17 +3,18 @@
   "version": "1.0.0",
   "description": "Library shared between the editor server and clients.",
   "main": "index.js",
-  "types": "types/index.js",
+  "types": "types/index.d.ts",
   "scripts": {
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
     "lint": "eslint --ext .js --ext .cjs --max-warnings 0 --format unix .",
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "author": "team@overleaf.com",
   "license": "Proprietary",

+ 4 - 0
libraries/overleaf-editor-core/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 5 - 3
libraries/promise-utils/package.json

@@ -3,16 +3,18 @@
   "version": "0.1.0",
   "description": "utilities to help working with promises",
   "main": "index.js",
+  "types": "types/index.d.ts",
   "scripts": {
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
     "lint": "eslint --ext .js --ext .cjs --max-warnings 0 --format unix .",
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "author": "Overleaf (https://www.overleaf.com)",
   "license": "AGPL-3.0-only",

+ 4 - 0
libraries/promise-utils/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 4 - 3
libraries/ranges-tracker/package.json

@@ -12,11 +12,12 @@
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "devDependencies": {
     "mocha": "^10.2.0",

+ 4 - 0
libraries/ranges-tracker/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 5 - 3
libraries/redis-wrapper/package.json

@@ -3,6 +3,7 @@
   "version": "2.1.0",
   "description": "Redis wrapper for node which will either use cluster or single instance redis",
   "main": "index.js",
+  "types": "types/index.d.ts",
   "files": [
     "index.js",
     "Errors.js",
@@ -17,11 +18,12 @@
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "peerDependencies": {
     "@overleaf/logger": "*",

+ 4 - 0
libraries/redis-wrapper/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 6 - 3
libraries/settings/package.json

@@ -3,16 +3,19 @@
   "description": "A centralised settings system for Overleaf",
   "version": "3.0.0",
   "repository": "overleaf/settings-module",
+  "main": "index.js",
+  "types": "types/index.d.ts",
   "scripts": {
     "lint": "eslint --ext .js --ext .cjs --max-warnings 0 --format unix .",
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "devDependencies": {
     "mocha": "^10.2.0",

+ 4 - 0
libraries/settings/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 5 - 4
libraries/stream-utils/package.json

@@ -3,17 +3,18 @@
   "version": "0.1.0",
   "description": "stream handling utilities",
   "main": "index.js",
-  "types": "types/index.js",
+  "types": "types/index.d.ts",
   "scripts": {
-    "test": "npm run lint && npm run format && npm run typecheck && npm run test:unit",
+    "test": "npm run lint && npm run format && npm run types:check && npm run test:unit",
     "test:unit": "mocha --exit test/**/*.{js,cjs}",
     "lint": "eslint --ext .js --ext .cjs --max-warnings 0 --format unix .",
     "lint:fix": "eslint --fix --ext .js --ext .cjs .",
     "format": "prettier --list-different $PWD/'**/*.{js,cjs}'",
     "format:fix": "prettier --write $PWD/'**/*.{js,cjs}'",
     "test:ci": "npm run test:unit",
-    "typecheck": "tsc --noEmit",
-    "update-types": "rm -rf types && tsc --emitDeclarationOnly"
+    "types:build": "[ -d types ] || tsc --emitDeclarationOnly",
+    "types:check": "tsc --noEmit",
+    "types:rebuild": "rm -rf types && npm run types:build"
   },
   "author": "Overleaf (https://www.overleaf.com)",
   "license": "AGPL-3.0-only",

+ 4 - 0
libraries/stream-utils/tsconfig.json

@@ -1,5 +1,9 @@
 {
   "extends": "../../tsconfig.backend.json",
+  "compilerOptions": {
+    "declaration": true,
+    "outDir": "types"
+  },
   "include": [
     "**/*.js",
     "**/*.cjs"

+ 17 - 3
services/chat/Makefile

@@ -33,6 +33,9 @@ MONOREPO=$(shell cd ../../ && pwd)
 # Eslint and prettier (plus some configs) are on the root.
 RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
 
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
+
 format:
 	$(RUN_LINTING) format
 
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -112,4 +118,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 1 - 1
services/chat/package.json

@@ -15,7 +15,7 @@
     "format": "prettier --list-different $PWD/'**/*.js'",
     "format:fix": "prettier --write $PWD/'**/*.js'",
     "lint:fix": "eslint --fix .",
-    "typecheck": "tsc --noEmit"
+    "types:check": "tsc --noEmit"
   },
   "dependencies": {
     "@overleaf/logger": "*",

+ 17 - 3
services/clsi/Makefile

@@ -33,6 +33,9 @@ MONOREPO=$(shell cd ../../ && pwd)
 # Eslint and prettier (plus some configs) are on the root.
 RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
 
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
+
 format:
 	$(RUN_LINTING) format
 
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -126,4 +132,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 2 - 1
services/clsi/package.json

@@ -13,7 +13,8 @@
     "lint": "eslint --max-warnings 0 --format unix .",
     "format": "prettier --list-different $PWD/'**/*.js'",
     "format:fix": "prettier --write $PWD/'**/*.js'",
-    "lint:fix": "eslint --fix ."
+    "lint:fix": "eslint --fix .",
+    "types:check": "tsc --noEmit"
   },
   "dependencies": {
     "@overleaf/fetch-utils": "*",

+ 17 - 3
services/contacts/Makefile

@@ -33,6 +33,9 @@ MONOREPO=$(shell cd ../../ && pwd)
 # Eslint and prettier (plus some configs) are on the root.
 RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
 
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
+
 format:
 	$(RUN_LINTING) format
 
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -112,4 +118,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 2 - 1
services/contacts/package.json

@@ -14,7 +14,8 @@
     "lint": "eslint --max-warnings 0 --format unix .",
     "format": "prettier --list-different $PWD/'**/*.js'",
     "format:fix": "prettier --write $PWD/'**/*.js'",
-    "lint:fix": "eslint --fix ."
+    "lint:fix": "eslint --fix .",
+    "types:check": "tsc --noEmit"
   },
   "dependencies": {
     "@overleaf/logger": "*",

+ 17 - 3
services/docstore/Makefile

@@ -33,6 +33,9 @@ MONOREPO=$(shell cd ../../ && pwd)
 # Eslint and prettier (plus some configs) are on the root.
 RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
 
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
+
 format:
 	$(RUN_LINTING) format
 
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -112,4 +118,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 2 - 1
services/docstore/package.json

@@ -13,7 +13,8 @@
     "lint": "eslint --max-warnings 0 --format unix .",
     "format": "prettier --list-different $PWD/'**/*.js'",
     "format:fix": "prettier --write $PWD/'**/*.js'",
-    "lint:fix": "eslint --fix ."
+    "lint:fix": "eslint --fix .",
+    "types:check": "tsc --noEmit"
   },
   "dependencies": {
     "@overleaf/logger": "*",

+ 17 - 3
services/document-updater/Makefile

@@ -33,6 +33,9 @@ MONOREPO=$(shell cd ../../ && pwd)
 # Eslint and prettier (plus some configs) are on the root.
 RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
 
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
+
 format:
 	$(RUN_LINTING) format
 
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -112,4 +118,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 2 - 1
services/document-updater/package.json

@@ -14,7 +14,8 @@
     "lint": "eslint --max-warnings 0 --format unix .",
     "format": "prettier --list-different $PWD/'**/*.js'",
     "format:fix": "prettier --write $PWD/'**/*.js'",
-    "lint:fix": "eslint --fix ."
+    "lint:fix": "eslint --fix .",
+    "types:check": "tsc --noEmit"
   },
   "dependencies": {
     "@overleaf/logger": "*",

+ 17 - 3
services/filestore/Makefile

@@ -33,6 +33,9 @@ MONOREPO=$(shell cd ../../ && pwd)
 # Eslint and prettier (plus some configs) are on the root.
 RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
 
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
+
 format:
 	$(RUN_LINTING) format
 
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -126,4 +132,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 2 - 1
services/filestore/package.json

@@ -15,7 +15,8 @@
     "format:fix": "prettier --write $PWD/'**/*.js'",
     "test:acceptance:_run": "mocha --recursive --reporter spec --timeout 15000 --exit $@ test/acceptance/js",
     "test:unit:_run": "mocha --recursive --reporter spec $@ test/unit/js",
-    "lint:fix": "eslint --fix ."
+    "lint:fix": "eslint --fix .",
+    "types:check": "tsc --noEmit"
   },
   "dependencies": {
     "@overleaf/logger": "*",

+ 17 - 3
services/history-v1/Makefile

@@ -33,6 +33,9 @@ MONOREPO=$(shell cd ../../ && pwd)
 # Eslint and prettier (plus some configs) are on the root.
 RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
 
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
+
 format:
 	$(RUN_LINTING) format
 
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -112,4 +118,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 2 - 1
services/history-v1/package.json

@@ -63,6 +63,7 @@
     "migrate": "knex migrate:latest",
     "delete_old_chunks": "node storage/tasks/delete_old_chunks.js",
     "fix_duplicate_versions": "node storage/tasks/fix_duplicate_versions.js",
-    "benchmarks": "node benchmarks/index.js"
+    "benchmarks": "node benchmarks/index.js",
+    "types:check": "tsc --noEmit"
   }
 }

+ 17 - 3
services/notifications/Makefile

@@ -33,6 +33,9 @@ MONOREPO=$(shell cd ../../ && pwd)
 # Eslint and prettier (plus some configs) are on the root.
 RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
 
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
+
 format:
 	$(RUN_LINTING) format
 
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -112,4 +118,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 2 - 1
services/notifications/package.json

@@ -13,7 +13,8 @@
     "lint": "eslint --max-warnings 0 --format unix .",
     "format": "prettier --list-different $PWD/'**/*.js'",
     "format:fix": "prettier --write $PWD/'**/*.js'",
-    "lint:fix": "eslint --fix ."
+    "lint:fix": "eslint --fix .",
+    "types:check": "tsc --noEmit"
   },
   "author": "",
   "license": "ISC",

+ 17 - 3
services/project-history/Makefile

@@ -33,6 +33,9 @@ MONOREPO=$(shell cd ../../ && pwd)
 # Eslint and prettier (plus some configs) are on the root.
 RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
 
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
+
 format:
 	$(RUN_LINTING) format
 
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -112,4 +118,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 2 - 1
services/project-history/package.json

@@ -14,7 +14,8 @@
     "lint": "eslint --max-warnings 0 --format unix .",
     "format": "prettier --list-different $PWD/'**/*.js'",
     "format:fix": "prettier --write $PWD/'**/*.js'",
-    "lint:fix": "eslint --fix ."
+    "lint:fix": "eslint --fix .",
+    "types:check": "tsc --noEmit"
   },
   "dependencies": {
     "@overleaf/fetch-utils": "*",

+ 17 - 3
services/real-time/Makefile

@@ -33,6 +33,9 @@ MONOREPO=$(shell cd ../../ && pwd)
 # Eslint and prettier (plus some configs) are on the root.
 RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
 
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
+
 format:
 	$(RUN_LINTING) format
 
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -105,4 +111,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 2 - 1
services/real-time/package.json

@@ -13,7 +13,8 @@
     "lint": "eslint --max-warnings 0 --format unix .",
     "format": "prettier --list-different $PWD/'**/*.js'",
     "format:fix": "prettier --write $PWD/'**/*.js'",
-    "lint:fix": "eslint --fix ."
+    "lint:fix": "eslint --fix .",
+    "types:check": "tsc --noEmit"
   },
   "dependencies": {
     "@hapi/joi": "^17.1.1",

+ 1 - 1
services/spelling/.nvmrc

@@ -1 +1 @@
-18.18.2-buster
+18.18.2

+ 18 - 4
services/spelling/Makefile

@@ -31,7 +31,10 @@ HERE=$(shell pwd)
 MONOREPO=$(shell cd ../../ && pwd)
 # Run the linting commands in the scope of the monorepo.
 # Eslint and prettier (plus some configs) are on the root.
-RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2-buster npm run --silent
+RUN_LINTING = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(HERE) node:18.18.2 npm run --silent
+
+# Same but from the top of the monorepo
+RUN_LINTING_MONOREPO = docker run --rm -v $(MONOREPO):$(MONOREPO) -w $(MONOREPO) node:18.18.2 npm run --silent
 
 format:
 	$(RUN_LINTING) format
@@ -45,8 +48,11 @@ lint:
 lint_fix:
 	$(RUN_LINTING) lint:fix
 
-typecheck:
-	$(RUN_LINTING) typecheck
+build_types:
+	$(RUN_LINTING_MONOREPO) --workspaces --if-present types:build
+
+typecheck: build_types
+	$(RUN_LINTING) types:check
 
 test: format lint typecheck test_unit test_acceptance
 
@@ -126,4 +132,12 @@ publish:
 	docker push $(DOCKER_REPO)/$(PROJECT_NAME):$(BRANCH_NAME)-$(BUILD_NUMBER)
 
 
-.PHONY: clean test test_unit test_acceptance test_clean benchmarks build publish
+.PHONY: clean \
+	format format_fix \
+	lint lint_fix \
+	build_types typecheck \
+	test test_clean test_unit test_unit_clean \
+	test_acceptance test_acceptance_debug test_acceptance_pre_run \
+	test_acceptance_run test_acceptance_run_debug test_acceptance_clean \
+	benchmarks \
+	build tar publish \

+ 1 - 1
services/spelling/buildscript.txt

@@ -5,6 +5,6 @@ spelling
 --env-add=
 --env-pass-through=
 --esmock-loader=True
---node-version=18.18.2-buster
+--node-version=18.18.2
 --public-repo=False
 --script-version=4.5.0

+ 2 - 1
services/spelling/package.json

@@ -19,7 +19,8 @@
     "lint": "eslint --max-warnings 0 --format unix .",
     "format": "prettier --list-different $PWD/'**/*.js'",
     "format:fix": "prettier --write $PWD/'**/*.js'",
-    "lint:fix": "eslint --fix ."
+    "lint:fix": "eslint --fix .",
+    "types:check": "tsc --noEmit"
   },
   "version": "0.1.4",
   "dependencies": {

+ 4 - 2
services/web/Dockerfile

@@ -34,7 +34,10 @@ FROM deps-prod as deps
 
 ENV CYPRESS_INSTALL_BINARY=0
 
-RUN cd /overleaf && npm install
+COPY tsconfig.backend.json /overleaf/
+RUN cd /overleaf \
+ && npm install \
+ && npm run --workspaces --if-present types:build
 
 # the web image with only production dependencies but no webpack production build, for development
 FROM deps-prod as app-only
@@ -49,7 +52,6 @@ FROM deps as dev
 
 ARG SENTRY_RELEASE
 ENV SENTRY_RELEASE=$SENTRY_RELEASE
-COPY tsconfig.backend.json /overleaf/
 COPY services/web /overleaf/services/web
 
 # Build the latex parser