🏷️(app-desk) add custom-next.d.ts file

Add custom-next.d.ts file to augment types.
We add our environment variables to avoid mispelling
and to have better autocompletion.
This commit is contained in:
Anthony LC
2024-01-18 13:11:15 +01:00
committed by Anthony LC
parent e2618d0e11
commit 30721b9ef9
2 changed files with 18 additions and 1 deletions

View File

@@ -0,0 +1,11 @@
/* eslint-disable @typescript-eslint/no-unused-vars */
namespace NodeJS {
interface ProcessEnv {
NEXT_PUBLIC_API_URL: string;
NEXT_PUBLIC_KEYCLOAK_URL: string;
NEXT_PUBLIC_KEYCLOAK_REALM: string;
NEXT_PUBLIC_KEYCLOAK_CLIENT_ID: string;
NEXT_PUBLIC_KEYCLOAK_LOGIN: string;
}
}

View File

@@ -22,6 +22,12 @@
"@/*": ["./src/*"]
}
},
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
"include": [
"src/custom-next.d.ts",
"next-env.d.ts",
"**/*.ts",
"**/*.tsx",
".next/types/**/*.ts"
],
"exclude": ["node_modules"]
}