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

fix(instantsearch): keep algoliasearch-helper as external dependency during build #5765

Merged
merged 4 commits into from
Jul 19, 2023

Conversation

dhayab
Copy link
Member

@dhayab dhayab commented Jul 19, 2023

Summary

Since the integration of the algoliasearch-helper to the monorepo, it is locally linked to other packages that depend on it (most notably, instantsearch.js). This created an issue during the building of the UMD version of the package, where babel doesn't transpile the helper dependency because now it is locally linked thanks to lerna.

This PR adds a babel configuration option that forces the library to be transpiled.

Result

InstantSearch.js's UMD package now works correctly and doesn't throw an error at runtime.

CR-3961
Closes #5763

@codesandbox-ci
Copy link

codesandbox-ci bot commented Jul 19, 2023

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit eb04561:

Sandbox Source
InstantSearch.js Configuration
react-instantsearch-app Configuration
example-react-instantsearch-hooks-default-theme Configuration
example-vue-instantsearch-default-theme Configuration
xenodochial-driscoll-cx7f74 Issue #5763

@dhayab
Copy link
Member Author

dhayab commented Jul 19, 2023

I'm working on a follow-up PR that will run an UMD e-commerce example on e2e, so that we can detect issues at runtime with this specific use-case.

@dhayab dhayab changed the title fix(instantsearch): transpile locally linked helper dependency fix(instantsearch): keep algoliasearch-helper as external dependency during build Jul 19, 2023
@Haroenv Haroenv merged commit 550fefa into master Jul 19, 2023
@Haroenv Haroenv deleted the fix/instantsearch-transpile-helper branch July 19, 2023 11:26
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.

"Uncaught ReferenceError: module is not defined" with the latest 4.56.6 version
2 participants