You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I run this using vite, by way of astro.js, the following error occurs:
/@fs/home/brian/work/portfoliome/censible-core/vendor/PapaParse/papaparse.js:920
var Duplex = require('stream').Duplex;
^
ReferenceError: require is not defined
at new DuplexStreamStreamer (/@fs/home/brian/work/portfoliome/censible-core/vendor/PapaParse/papaparse.js:920:16)
The problem is the "browser" export is used instead of the "main" export on the server side.
/@fs/home/brian/work/portfoliome/censible-core/vendor/PapaParse/papaparse.js:920
var Duplex = require('stream').Duplex;
^
ReferenceError: require is not defined
at new DuplexStreamStreamer (/@fs/home/brian/work/portfoliome/censible-core/vendor/PapaParse/papaparse.js:920:16)
Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
Make sure this is a Vite issue and not a framework-specific issue. For example, if it's a Vue SFC related bug, it should likely be reported to vuejs/core instead.
Hello @btakita. Please provide a minimal reproduction using a GitHub repository or StackBlitz. Issues marked with need reproduction will be closed if they have no activity within 3 days.
Describe the bug
I'm working on a PR for papaparse to support ESM.
mholt/PapaParse#978
Part of the solution is to add
package.json
into theesm
directory:When I run this using vite, by way of astro.js, the following error occurs:
The problem is the "browser" export is used instead of the "main" export on the server side.
Reproduction
mholt/PapaParse#978
Steps to reproduce
Use commit 12d09d54f6e79f05eabb5fb61f0de582ff63f511 as a dependency to a vite server side project or an astro.js project.
System Info
Used Package Manager
npm
Logs
Validations
The text was updated successfully, but these errors were encountered: