Explorar o código

fix: idk whats going on

Sv443 hai 4 meses
pai
achega
47c1648cd3
Modificáronse 3 ficheiros con 22 adicións e 31 borrados
  1. 3 2
      package.json
  2. 12 22
      pnpm-lock.yaml
  3. 7 7
      tsconfig.json

+ 3 - 2
package.json

@@ -6,12 +6,12 @@
   "type": "module",
   "scripts": {
     "dev": "nodemon -e \"ts,d.ts,json\" -x \"pnpm start\"",
-    "start": "tsc && node --no-warnings=ExperimentalWarning --enable-source-maps out/src/index.js",
+    "start": "tsx src/index.ts",
     "dev-www": "cd www && pnpm run dev",
     "build-www": "cd www && pnpm run build",
     "dev-all": "concurrently \"pnpm dev\" \"pnpm dev-www\"",
     "lint": "eslint . && tsc --noEmit",
-    "test": "start-server-and-test start http://localhost:8074 jest"
+    "test": "start-server-and-test start http://127.0.0.1:8074 jest"
   },
   "repository": {
     "type": "git",
@@ -74,6 +74,7 @@
     "pnpm": "^9.14.2",
     "start-server-and-test": "^2.0.8",
     "ts-jest": "^29.2.5",
+    "ts-node": "^10.9.2",
     "tslib": "^2.8.1"
   },
   "nodemonConfig": {

+ 12 - 22
pnpm-lock.yaml

@@ -111,6 +111,9 @@ importers:
       ts-jest:
         specifier: ^29.2.5
         version: 29.2.5(@babel/[email protected])(@jest/[email protected])(@jest/[email protected])([email protected](@babel/[email protected]))([email protected](@types/[email protected])([email protected](@types/[email protected])([email protected])))([email protected])
+      ts-node:
+        specifier: ^10.9.2
+        version: 10.9.2(@types/[email protected])([email protected])
       tslib:
         specifier: ^2.8.1
         version: 2.8.1
@@ -3177,7 +3180,6 @@ snapshots:
   '@cspotcode/[email protected]':
     dependencies:
       '@jridgewell/trace-mapping': 0.3.9
-    optional: true
 
   '@esbuild/[email protected]':
     optional: true
@@ -3554,7 +3556,6 @@ snapshots:
     dependencies:
       '@jridgewell/resolve-uri': 3.1.2
       '@jridgewell/sourcemap-codec': 1.5.0
-    optional: true
 
   '@mdit-vue/[email protected]':
     dependencies:
@@ -3635,17 +3636,13 @@ snapshots:
     dependencies:
       '@sinonjs/commons': 3.0.1
 
-  '@tsconfig/[email protected]':
-    optional: true
+  '@tsconfig/[email protected]': {}
 
-  '@tsconfig/[email protected]':
-    optional: true
+  '@tsconfig/[email protected]': {}
 
-  '@tsconfig/[email protected]':
-    optional: true
+  '@tsconfig/[email protected]': {}
 
-  '@tsconfig/[email protected]':
-    optional: true
+  '@tsconfig/[email protected]': {}
 
   '@types/[email protected]':
     dependencies:
@@ -4085,7 +4082,6 @@ snapshots:
   [email protected]:
     dependencies:
       acorn: 8.14.0
-    optional: true
 
   [email protected]: {}
 
@@ -4115,8 +4111,7 @@ snapshots:
       normalize-path: 3.0.0
       picomatch: 2.3.1
 
-  [email protected]:
-    optional: true
+  [email protected]: {}
 
   [email protected]: {}
 
@@ -4410,8 +4405,7 @@ snapshots:
       - supports-color
       - ts-node
 
-  [email protected]:
-    optional: true
+  [email protected]: {}
 
   [email protected]:
     dependencies:
@@ -4469,8 +4463,7 @@ snapshots:
 
   [email protected]: {}
 
-  [email protected]:
-    optional: true
+  [email protected]: {}
 
   [email protected]:
     dependencies:
@@ -6105,7 +6098,6 @@ snapshots:
       typescript: 5.7.2
       v8-compile-cache-lib: 3.0.1
       yn: 3.1.1
-    optional: true
 
   [email protected]: {}
 
@@ -6162,8 +6154,7 @@ snapshots:
 
   [email protected]: {}
 
-  [email protected]:
-    optional: true
+  [email protected]: {}
 
   [email protected]:
     dependencies:
@@ -6257,7 +6248,6 @@ snapshots:
       y18n: 5.0.8
       yargs-parser: 21.1.1
 
-  [email protected]:
-    optional: true
+  [email protected]: {}
 
   [email protected]: {}

+ 7 - 7
tsconfig.json

@@ -25,11 +25,12 @@
     "strict": true,
     "useDefineForClassFields": true,
     "noImplicitThis": false,
+    "allowImportingTsExtensions": false,
     "paths": {
       "@src/*": ["src/*"],
       "@routes/*": ["src/routes/*"],
       "@www/*": ["www/*"],
-      "@root/*": ["."],
+      "@root/*": ["*"],
     }
   },
   "ts-node": {
@@ -37,13 +38,12 @@
     "preferTsExts": true,
   },
   "include": [
-    "src/**/*.ts",
-    "src/**/*.d.ts",
-    "www/**/*.ts",
-    "www/**/*.d.ts",
+    "src/**/*",
+    "www/**/*",
   ],
   "exclude": [
-    "**/dist/**",
-    "**/dev/**",
+    "**/node_modules/**/*",
+    "**/dist/**/*",
+    "**/dev/**/*",
   ],
 }