Skip to content

Commit a12f394

Browse files
authored
fix(loaders): conflict with codegen also using TypeScriptLoader(), causing a double ts-node register. (#1149)
1 parent bdfb330 commit a12f394

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/lazy-pens-join.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'graphql-config': patch
3+
---
4+
5+
conflict with codegen also using TypeScriptLoader(), causing a double ts-node register.

src/helpers/cosmiconfig.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ function prepareCosmiconfig(moduleName: string, { legacy }: { legacy: boolean })
8181
return {
8282
searchPlaces: searchPlaces.map((place) => place.replace('#', moduleName)),
8383
loaders: {
84-
'.ts': TypeScriptLoader(),
84+
'.ts': TypeScriptLoader({ transpileOnly: true }),
8585
'.js': defaultLoaders['.js'],
8686
'.json': loadJson,
8787
'.yaml': loadYaml,

0 commit comments

Comments
 (0)