Closed RobKohr closed 10 months ago
Thanks for reporting the issue, we'll get that fixed quickly.
In the meantime, to work around that issue, you can use the specPathGlobs
option to set only your source files(e.g. "src/*/.ts") to not include node_modules
. You can find more information on how to do this at https://ts-spec.github.io/tspec/guide/generating-document.
I'll let you know if this issue is resolved.
I tried configuring the project as written in https://ts-spec.github.io/tspec/guide/getting-started to reproduce the issue you reported, but the issue didn't occur. Can you give me more details about the environment where the issue occurred?
Also, when Tspec load the type files, it ignores **/node_modules/**
as you can see in the code attached below, so it's strange that it shouldn't happen 🤔.
Oh, I figured it out. I set the "rootDir": "../" in order to import routes that were outside of the server's directory in the tsconfig. I was keeping api route files next to their related front end component files and this created issues. I moved them into the server directory and got rid of the rootDir setting and now it looks only where it is supposed to.
Despite not having anything about pets in my code, I am seeing a pets api on my docs.
It looks like it is loading in the pet info from: node_modules/tspec/dist/tests/pet.js
Is there a way to have it ignore this?