Skip to content

Doesn't appear to look for index.d.ts if main field of package.json is listed as a different name #217

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
jamesbrobb opened this issue Jul 11, 2024 · 0 comments

Comments

@jamesbrobb
Copy link

In the README point 2 under "Order of Operations" states:

  1. Finds a .d.ts file, checking to see if one was specified manually or in the types field of the package.json. If neither is found, attempts to find one in the project directory named the same as the main field of the package.json or index.d.ts. Fails if no .d.ts file is found.

I'm not finding this to be the case. My main field is public-api.js but i have an index.d.ts file in the project directory i'm targeting, but am still getting the following error:

The type definition public-api.d.ts does not exist at...

Obviously if i rename index.d.ts to public-api.d.ts it works, so it this a mistake in the README explanation?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant