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

Update buildchain to use rollup in order to improve esm support #248

Closed
wants to merge 1 commit into from

Conversation

cea2aj
Copy link
Member

@cea2aj cea2aj commented Sep 13, 2023

The library exported an esm version, however it didn't work with all esm tools becase some require "type": "module" to be set, or the files to end in ".mjs". By moving over to rollup, we can output the esm files with the ".mjs" extension which makes this library work with vite.

This change is based on the approach which Chat decided on: yext/chat-ui-react#38

J=BACK-2527
TEST=manual

Manually ran the test site locally and confirmed the requests still fire correctly. I still need to test this with vite.

The library exported an esm version, however it didn't work
with all esm tools becase some require "type": "module" to be
set, or the files to end in ".mjs". By moving over to rollup,
we can output the esm files with the ".mjs" extension which
makes this library work with vite.

This change is based on the approach which Chat decided on:
yext/chat-ui-react#38

J=BACK-2527
TEST=manual

Manually ran the test site locally and confirmed the requests
still fire correctly. I still need to test this with vite.
@cea2aj cea2aj requested a review from a team as a code owner September 13, 2023 18:46
@coveralls
Copy link

Pull Request Test Coverage Report for Build 6176585419

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.02%) to 90.588%

Totals Coverage Status
Change from base Build 5534802473: -0.02%
Covered Lines: 218
Relevant Lines: 235

💛 - Coveralls

@cea2aj
Copy link
Member Author

cea2aj commented Sep 13, 2023

Upon further testing, the existing library works just fine with the pages js dev and prod builds, so I don't think this change is needed

@cea2aj cea2aj closed this Sep 26, 2023
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.

None yet

2 participants