- 
                Notifications
    You must be signed in to change notification settings 
- Fork 22
Description
Hi @Haroenv and other maintainers 👋 Hope you are well! Thanks again for your continued effort on the projects in the Algolia ecosystem!
I'm not sure if I'm reporting this in the right place, but I wanted to reach out about what appears to be a data problem with npm-search index (we've only seen a single library so far):
Running index.getObject() with the package name yup returns the following:
{
  types: {
    ts: 'definitely-typed',
    definitelyTyped: '@types/yup',
  },
}However, on the npm website, the yup package is reported as having built-in types and the @types/yup package has been deprecated:
Both the current version and the beta version of yup have no "types" or "typings" keys in the package.json:
- https://unpkg.com/browse/[email protected]/package.json
- https://unpkg.com/browse/[email protected]/package.json
For the current [email protected], there is however no index.d.ts in the root:
But there is one in [email protected]:
Is the npm website or Algolia's index wrong? (seems like npm website is wrong 🤔)
Our usage:
const client = algoliasearch(
  'XXX',
  'xxxxxxxxxxx',
);
const index = client.initIndex('npm-search');
const results = await index.getObject<AlgoliaObj>(dependency, {
  attributesToRetrieve: ['types'],
});
const definitelyTypedPackageName = results.types?.definitelyTyped;
