diff --git a/backend/package.json b/backend/package.json index 6c4c505a4e4d1ff510adfb325d2ff3dee441d4ad..03cde72d508ab6e3239b33ea306c01c744992fc0 100644 --- a/backend/package.json +++ b/backend/package.json @@ -4,8 +4,9 @@ "description": "Ötzi game backend.", "main": "src/index.js", "scripts": { - "serve": "nodemon src/index.ts", "build": "tsc", + "start": "NODE_PATH=./dist node dist/index.js", + "serve": "nodemon src/index.ts", "lint:check": "eslint .", "lint:fix": "eslint . --fix", "format:check": "prettier . --check", diff --git a/backend/tsconfig.json b/backend/tsconfig.json index 6ce8041615ded3aa47bb7d359270aebe3786140b..8de0c07f1960eea1d766a9d5fb7927932f5657e5 100644 --- a/backend/tsconfig.json +++ b/backend/tsconfig.json @@ -1,13 +1,21 @@ { "compilerOptions": { + /* Visit https://aka.ms/tsconfig.json to read more about this file */ + + // Node 16 recommendations -- https://github.com/tsconfig/bases/blob/main/bases/node16.json + "lib": ["ES2021"], "module": "commonjs", - "target": "es6", - "declaration": true, - "lib": ["ES6", "DOM"], - "outDir": "dist", - "rootDir": "src", + "target": "ES2021", "strict": true, - "typeRoots": ["./node_modules/@types"] + "esModuleInterop": true, + "skipLibCheck": true, + "forceConsistentCasingInFileNames": true, + + // Customization + //"moduleResolution": "node", + "rootDir": "./src", + "baseUrl": "./src", + "outDir": "./dist" }, "include": ["src/**/*"], "exclude": ["src/**/*.spec.ts"]