api-clients-automation
api-clients-automation copied to clipboard
feat(clients): support recommend methods in `algoliasearch`
🧠What and Why
As we're trying to unify FX libraries, we want to avoid requiring users to import a bunch of different packages. We've made those changes to v4 : https://github.com/algolia/algoliasearch-client-javascript/pull/1509
🎟 JIRA Ticket: FX-2774
Changes included:
I'm publishing this as a draft as I'm overall not too sure about the best way to implement this :
- I opted to merge the
search
andrecommend
specs foralgoliasearch/lite
, and it works well however this will have repercussions for the Dart client (cc @aallam) - For the
algoliasearch
part (not lite), I'm a bit torn as methods are not exported so we can't have the same treeshaking we have with v4,createRecommend
has to be called and the bundle will have redundant code. Running into problems with similar models being exported too. Also didn't update it for Dart but it might be fine for now.
🧪 Test
Didn't bother with tests yet as this is subject to change :D
🔨 The codegen job will run at the end of the CI.
Make sure your last commit does not contain generated code, it will be automatically pushed by our CI.
thanks for the contribution! I actually had a local branch for this feature, I'll add them to your branch and push so we can discuss it :)
had trouble merging our changes, so I've applied some of yours on my PR, which should make the test pass https://github.com/algolia/api-clients-automation/pull/2860, let me know wdyt
superseded by https://github.com/algolia/api-clients-automation/pull/2860