yuanjiajun
commited on
Commit
·
cdbeb05
1
Parent(s):
35a938e
feat: 变量
Browse files- Dockerfile +1 -1
- package-lock.json +0 -0
- package.json +1 -0
- tsconfig.json +5 -4
Dockerfile
CHANGED
|
@@ -23,4 +23,4 @@ EXPOSE 3000
|
|
| 23 |
ENV PORT=3000
|
| 24 |
|
| 25 |
# 启动应用
|
| 26 |
-
CMD ["npm ", "
|
|
|
|
| 23 |
ENV PORT=3000
|
| 24 |
|
| 25 |
# 启动应用
|
| 26 |
+
CMD ["npm ", "start"]
|
package-lock.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
package.json
CHANGED
|
@@ -5,6 +5,7 @@
|
|
| 5 |
"main": "build/app.js",
|
| 6 |
"scripts": {
|
| 7 |
"dev": "nodemon",
|
|
|
|
| 8 |
"lint": "eslint --ext .ts src --fix"
|
| 9 |
},
|
| 10 |
"repository": {
|
|
|
|
| 5 |
"main": "build/app.js",
|
| 6 |
"scripts": {
|
| 7 |
"dev": "nodemon",
|
| 8 |
+
"start": "ts-node -r tsconfig-paths/register ./src/app.ts",
|
| 9 |
"lint": "eslint --ext .ts src --fix"
|
| 10 |
},
|
| 11 |
"repository": {
|
tsconfig.json
CHANGED
|
@@ -4,16 +4,17 @@
|
|
| 4 |
"module": "commonjs",
|
| 5 |
"outDir": "./dist",
|
| 6 |
"rootDir": "./src",
|
|
|
|
| 7 |
"strict": true,
|
| 8 |
"skipLibCheck": true,
|
| 9 |
"forceConsistentCasingInFileNames": true,
|
| 10 |
"esModuleInterop": true,
|
| 11 |
"allowSyntheticDefaultImports": true,
|
| 12 |
-
"baseUrl": "
|
| 13 |
"paths": {
|
| 14 |
-
"@/*": ["src/*"]
|
| 15 |
-
}
|
| 16 |
},
|
| 17 |
-
|
| 18 |
"exclude": ["node_modules", "dist"]
|
| 19 |
}
|
|
|
|
| 4 |
"module": "commonjs",
|
| 5 |
"outDir": "./dist",
|
| 6 |
"rootDir": "./src",
|
| 7 |
+
"moduleResolution": "node",
|
| 8 |
"strict": true,
|
| 9 |
"skipLibCheck": true,
|
| 10 |
"forceConsistentCasingInFileNames": true,
|
| 11 |
"esModuleInterop": true,
|
| 12 |
"allowSyntheticDefaultImports": true,
|
| 13 |
+
"baseUrl": ".", // 对应文件系统中的根路径
|
| 14 |
"paths": {
|
| 15 |
+
"@/*": ["src/*"] // 将 @/ 映射到 src/ 目录
|
| 16 |
+
},
|
| 17 |
},
|
| 18 |
+
"include": ["src"],
|
| 19 |
"exclude": ["node_modules", "dist"]
|
| 20 |
}
|