Typescript: error TS5056: Cannot write file '/home/node/api/dist/src/datasources/admin.datasource.d.ts' because it would be overwritten by multiple input files

Created on 19 Nov 2019  路  5Comments  路  Source: microsoft/TypeScript


hi DEVS i get this problem after i try to run my server API , im using #angular 7 and #loopback
it seems like the is 2 fils pointing in the same datasources of base (client) and the same thing
happen to the (Admin database)
i found the 5054 erreur but is not the same my error is TS5056 ...
i thing is Typescript version ..im not sure any help plz

------this is my Api Tscofig

**{ "extends": "./node_modules/@loopback/build/config/tsconfig.common.json", "include": [ "src", "test" ], "exclude": [ "node_modules/**", "packages/*/node_modules/**", "examples/*/node_modules/**", "**/*.d.ts" ] }

**

------- the error is in the DIST->src ->datasources .... file auto generated by * npm start *

github

Duplicate

Most helpful comment

I've noticed that some of my projects now include *.d.ts outputs for json files. Since you have .ts and .json files with the same name, I guess that's the reason you're seeing the error.

I'm not sure if that behavior is intended.

All 5 comments

tsconfig

I've noticed that some of my projects now include *.d.ts outputs for json files. Since you have .ts and .json files with the same name, I guess that's the reason you're seeing the error.

I'm not sure if that behavior is intended.

See #34962 - JSON from .d.ts will be disabled in 3.7.3

This issue has been marked as a 'Duplicate' and has seen no recent activity. It has been automatically closed for house-keeping purposes.

Like @AlCalzone said the reason is files .ts and .json with the same name; I added at the and of the name .config.json in order to avoid this errors in datasources files.
Thank you very much @AlCalzone

Was this page helpful?
0 / 5 - 0 ratings

Related issues

kyasbal-1994 picture kyasbal-1994  路  3Comments

siddjain picture siddjain  路  3Comments

bgrieder picture bgrieder  路  3Comments

remojansen picture remojansen  路  3Comments

wmaurer picture wmaurer  路  3Comments