Finish making the intellisense work properly

This commit is contained in:
Eldritch-Oliver 2025-10-05 13:31:31 -06:00
parent 0917f28fcb
commit 98b429f941
3 changed files with 30 additions and 8 deletions

14
augments.d.ts vendored Normal file
View file

@ -0,0 +1,14 @@
declare global {
class Hooks extends foundry.helpers.Hooks {};
const fromUuid = foundry.utils.fromUuid;
}
interface Actor {
/** The system-specific data */
system: any;
};
interface Item {
/** The system-specific data */
system: any;
};

View file

@ -4,7 +4,7 @@ import stylistic from "@stylistic/eslint-plugin";
export default [ export default [
// Tell eslint to ignore files that I don't mind being formatted slightly differently // Tell eslint to ignore files that I don't mind being formatted slightly differently
{ ignores: [ `scripts/` ] }, { ignores: [ `scripts/`, `foundry/` ] },
{ {
languageOptions: { languageOptions: {
globals: globals.browser, globals: globals.browser,

View file

@ -1,11 +1,19 @@
{ {
"compilerOptions": { "compilerOptions": {
"module": "ES2020", "module": "es2022",
"target": "ES2020" "target": "es2022",
"types": [
"./augments.d.ts"
],
"paths": {
"@client/*": ["./foundry/client/*"],
"@common/*": ["./foundry/common/*"],
}
}, },
"exclude": ["node_modules", "**/node_modules/*"], "include": [
"include": ["module/**/*", "foundry.v13.link/client/**/*.js", "foundry.v13.link/**/*.mjs"], "module/**/*",
"typeAcquisition": { "foundry/client/client.mjs",
"include": ["jquery"] "foundry/client/global.d.mts",
} "foundry/common/primitives/global.d.mts"
]
} }