Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
was giving some odd errors with the buffer polyfill. vite is a little funny because at dev time, it uses esbuild, but rollup at production build. this was a dev only esbuild error
Example error from the esbuild globals plugin
The injected path "/home/cdiesh/src/jbrowse-components/embedded_demos/jbrowse-react-linear-genome-view-vite/node_modules/@esbuild-plugins/node-globals-polyfill/_buffer.js" cannot be marked as external
I switched in this PR to polyfill buffer in the entry point (src/main.tsx) rather than in the vite config. buffer and stream are the two main things we still need polyfills for afaik, as well as setting the "global" variable which may be related to the stream polyfill