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: add types to exports (v7.x) #1930

Merged
merged 1 commit into from
Jul 10, 2023
Merged

fix: add types to exports (v7.x) #1930

merged 1 commit into from
Jul 10, 2023

Conversation

Marsup
Copy link

@Marsup Marsup commented Jul 3, 2023

Hi,

Enabling ESM mode with TypeScript seems to cause this error to appear: Cannot find module '@elastic/elasticsearch' or its corresponding type declarations.(2307)

We're not ready yet to upgrade to v8.x which is why I'm patching v7.x, but it seems this error is also present in this version, and I'm not sure how to fix it yet, maybe it's as simple as declaring "type": "commonjs" in the package.json?

Copy link
Member

@JoshMock JoshMock left a comment

Choose a reason for hiding this comment

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

Good catch. Thanks @Marsup!

@JoshMock
Copy link
Member

Verified that all the failing/missing CI tests are unrelated to this change. Merging (finally)!

@JoshMock JoshMock merged commit e20ddc7 into elastic:7.x Jul 10, 2023
15 of 16 checks passed
@Marsup Marsup deleted the patch-1 branch July 11, 2023 14:02
JoshMock pushed a commit that referenced this pull request Jul 13, 2023
JoshMock added a commit that referenced this pull request Jul 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants