Skip to content
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

Add the searchForFacetValues method for Meilisearch v1.3.0 #1513

Conversation

bidoubiwa
Copy link
Contributor

@bidoubiwa bidoubiwa commented Jun 5, 2023

index.searchForFacetValue

A new method index.searchForFacetvalue method is introduced.

See explanation on this method here.

related PR

Usage example:

await client.index(index.uid).searchForFacetValue({
  facetQuery: 'act',
  facetName: 'genres',
})

@bidoubiwa bidoubiwa force-pushed the prototype-beta/prototype-search-for-facet-values branch from 54da022 to 1ea1f67 Compare June 5, 2023 15:12
@bidoubiwa bidoubiwa added the enhancement New feature or request label Jun 5, 2023
@bidoubiwa bidoubiwa marked this pull request as ready for review June 6, 2023 10:42
src/indexes.ts Outdated Show resolved Hide resolved
@bidoubiwa bidoubiwa force-pushed the prototype-beta/prototype-search-for-facet-values branch from 1ea1f67 to 75d7f34 Compare June 6, 2023 12:50
@bidoubiwa bidoubiwa requested a review from mdubus June 6, 2023 12:55
mdubus
mdubus previously approved these changes Jun 6, 2023
Copy link
Member

@mdubus mdubus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM ✨🦕

…et-values.0) (#1514)

* Update package.json

* Update src/package-version.ts
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
src/indexes.ts Outdated Show resolved Hide resolved
tests/facet_search.test.ts Outdated Show resolved Hide resolved
tests/facet_search.test.ts Outdated Show resolved Hide resolved
tests/facet_search.test.ts Outdated Show resolved Hide resolved
tests/facet_search.test.ts Outdated Show resolved Hide resolved
@bidoubiwa bidoubiwa changed the title Add the searchForFacetValue method Add the searchForFacetValues method Jun 7, 2023
package.json Outdated Show resolved Hide resolved
src/package-version.ts Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
tests/facet_search.test.ts Show resolved Hide resolved
tests/facet_search.test.ts Show resolved Hide resolved
Co-authored-by: Bruno Casali <brunoocasali@gmail.com>
@bidoubiwa bidoubiwa changed the title Add the searchForFacetValues method Meilisearch Prototype: Add the searchForFacetValues method Jun 13, 2023
@bidoubiwa bidoubiwa changed the base branch from main to bump-meilisearch-v1.3.0 July 10, 2023 14:43
@bidoubiwa bidoubiwa changed the title Meilisearch Prototype: Add the searchForFacetValues method Add the searchForFacetValues method for Meilisearch v1.3.0 Jul 10, 2023
@bidoubiwa bidoubiwa force-pushed the prototype-beta/prototype-search-for-facet-values branch from 7556d75 to 675ea17 Compare July 10, 2023 15:11
@bidoubiwa bidoubiwa force-pushed the prototype-beta/prototype-search-for-facet-values branch from 675ea17 to 969b509 Compare July 10, 2023 15:16
Comment on lines +92 to +94
facetHits: FacetHit[]
facetQuery: string | null
processingTimeMs: number
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this only these 3 keys that will be responded?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes!

 {
      facetHits: [ { value: 'adventure', count: 1 } ],
      facetQuery: 'a',
      processingTimeMs: 0
    }

Copy link
Member

@brunoocasali brunoocasali left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🧇

@bidoubiwa bidoubiwa merged commit b61a8e5 into bump-meilisearch-v1.3.0 Jul 12, 2023
@bidoubiwa bidoubiwa deleted the prototype-beta/prototype-search-for-facet-values branch July 12, 2023 14:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants