Skip to content

feat(js): client common #99

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

Merged
merged 1 commit into from
Jan 21, 2022
Merged

feat(js): client common #99

merged 1 commit into from
Jan 21, 2022

Conversation

shortcuts
Copy link
Member

🧭 What and Why

🎟 JIRA Ticket: https://algolia.atlassian.net/browse/APIC-251

Changes included:

  • Rename JavaScript utils package to client-common (to match the existing package in the current API client)
  • Use this package as a dependency in other clients

Motivations

It was annoying to have everything copied while trying to bundle the JavaScript client and implementing the XHR requester. This allow us to only have one entry point.

I think it would make sense to break down this common package in mini-ones, some of those features might not be useful in every clients.

We can improve this package (or the sub ones) in many ways, but in the meantime it's already good for dev purposes.

🧪 Test

CI :D

@shortcuts shortcuts requested review from millotp and a team January 20, 2022 16:49
@shortcuts shortcuts self-assigned this Jan 20, 2022
@shortcuts
Copy link
Member Author

Name is here for the sake of the historical one, https://www.npmjs.com/package/@algolia/client-common suggest if you want to rename

Copy link
Collaborator

@millotp millotp left a comment

Choose a reason for hiding this comment

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

Very clean !

Comment on lines +10 to +12
"generate": "yarn generate:methods:requets ${0:-javascript} ${1:-search} && yarn lint:fix",
"lint:fix": "yarn workspace javascript-tests lint:fix",
"start": "yarn build && yarn generate ${0:-javascript} ${1:-search}"
Copy link
Collaborator

Choose a reason for hiding this comment

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

This makes more sense, I changed this in #100 to work with all languages

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

Successfully merging this pull request may close these issues.

2 participants