diff --git a/.gitignore b/.gitignore index 07f080e26..9a5b85c45 100644 --- a/.gitignore +++ b/.gitignore @@ -9,4 +9,4 @@ node_modules/ /playwright-report/ /playwright/.cache/ $__StoryList.tid -types/generated/ +types/core/ diff --git a/tsconfig.json b/tsconfig.json index 4ec0bfc31..5398d26ba 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -12,15 +12,16 @@ "checkJs": true, "allowSyntheticDefaultImports": true, "declaration": true, - "declarationDir": "types/generated", + "declarationDir": "types/", "declarationMap": true, "emitDeclarationOnly": true, "lib": ["ES2020", "DOM", "DOM.Iterable"], "module": "Node16", - "outDir": "types/generated", + "outDir": "types/", "skipLibCheck": true, "target": "ESNext" }, - "include": ["./core/**/*.js", "./core/**/*.d.ts", "types/tw.d.ts"], - "exclude": ["types/generated"] + "include": ["./core/**/*.js", "./core/**/*.d.ts", "types/*.d.ts"], + // Exclude the generated types from the core folder + "exclude": ["types/core",] } diff --git a/types/tsconfig.json b/types/tsconfig.json index b98460aff..04a243375 100644 --- a/types/tsconfig.json +++ b/types/tsconfig.json @@ -4,17 +4,16 @@ // Allow `import('$:/core/modules/...')` instead of `import('../../core/modules/...')`. Only works inside this project. "$:/core/*": ["core/*"] }, - "baseUrl": "./generated", - "rootDir": "./generated", + "baseUrl": "./", + "rootDir": "./", "noEmit": true, "noImplicitAny": false, "allowSyntheticDefaultImports": true, "declaration": true, - "declarationDir": "types/generated", "lib": ["ES2020", "DOM", "DOM.Iterable"], "module": "Node16", "skipLibCheck": true, "target": "ESNext" }, - "include": ["./generated/**/*.d.ts"] + "include": ["./core/**/*.d.ts"] }