Skip to content

Commit

Permalink
fix(types): fix types path
Browse files Browse the repository at this point in the history
At the moment, due to an issue with a dependency I need to keep the rootDir at the root, this makes
it so that the output will contain src
  • Loading branch information
ntrp committed Jun 1, 2022
1 parent eb29e13 commit 2e603b8
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
],
"main": "dist/ksqldb-graphql.cjs.js",
"module": "dist/ksqldb-graphql.es5.js",
"types": "dist/types/ksqldb-graphql.d.ts",
"types": "dist/types/src/ksqldb-graphql.d.ts",
"files": [
"dist"
],
Expand Down
14 changes: 14 additions & 0 deletions src/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"compilerOptions": {
"rootDir": ".",
"declaration": true,
"declarationDir": "../dist/types",
"outDir": "../dist/lib",
"resolveJsonModule": true
},
"references": [ // this is how we declare a dependency from
{
"path": "../"
} // this project to the one at the root dir`
]
}
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
},
"include": [
"src",
// fix issues with rollup build
// fix issues with rollup build (this forces me also to keep the src folder in the types)
"node_modules/@josephg/resolvable"
]
}
1 change: 1 addition & 0 deletions tsconfig.tsbuildinfo

Large diffs are not rendered by default.

0 comments on commit 2e603b8

Please sign in to comment.