bugfix, ts target stuff

This commit is contained in:
Kaushik Narayan R 2025-03-11 22:59:00 -07:00
parent a74ffc453e
commit a6ecf7df88
4 changed files with 8 additions and 9 deletions

View File

@ -3,7 +3,7 @@ const authRouter: Router = Router();
import { login, callback, refresh, logout } from "../controllers/auth.ts";
import { isAuthenticated } from "../middleware/authCheck.ts";
import { validate } from "../validators/index.ts";
// import { validate } from "../validators/index.ts";
authRouter.get("/login", login);

View File

@ -3,7 +3,7 @@ const router: Router = Router();
import { fetchUserPlaylists } from "../controllers/playlists.ts";
import { validate } from "../validators/index.ts";
// import { validate } from "../validators/index.ts";
router.get("/me", fetchUserPlaylists);

View File

@ -1,6 +1,7 @@
{
"exclude": [
"./boilerplates"
"boilerplates",
"tsout"
],
"compilerOptions": {
/* Visit https://aka.ms/tsconfig to read more about this file */
@ -12,9 +13,9 @@
// "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */
// "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */
/* Language and Environment */
"target": "ESNext", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */
"target": "ES2024", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */
"lib": [
"ESNext"
"ES2024"
], /* Specify a set of bundled library declaration files that describe the target runtime environment. */
// "jsx": "preserve", /* Specify what JSX code is generated. */
// "libReplacement": true, /* Enable lib replacement. */
@ -28,9 +29,9 @@
"useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */
"moduleDetection": "force", /* Control what method is used to detect module-format JS files. */
/* Modules */
"module": "NodeNext", /* Specify what module code is generated. */
"module": "Node18", /* Specify what module code is generated. */
// "rootDir": "./", /* Specify the root folder within your source files. */
"moduleResolution": "nodenext", /* Specify how TypeScript looks up a file from a given module specifier. */
"moduleResolution": "node16", /* Specify how TypeScript looks up a file from a given module specifier. */
// "baseUrl": "./", /* Specify the base directory to resolve non-relative module names. */
// "paths": {}, /* Specify a set of entries that re-map imports to additional lookup locations. */
// "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */

View File

@ -3,5 +3,3 @@ export const sleep = (ms: number): Promise<unknown> =>
export const randomBool = (chance_of_failure = 0.25): boolean =>
Math.random() < chance_of_failure;
new Promise((resolve) => setTimeout(resolve, 100));