question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[vite:worker-import-meta-url] 'sep' is not exported by __vite-browser-external

See original GitHub issue

I’m experiencing the error while doing vite build for production: image

It’s strange. Other imports from the path module work.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:14 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
astoilkovcommented, Oct 7, 2022

Done. I’ve replicated the problem — https://github.com/astoilkov/electron-vite-worker-issue.

Run yarn run build and you will see this: CleanShot 2022-10-07 at 09 41 38@2x

This is causing an error when you run the app and click the “hello” text.

The issue is caused by:

  • graceful-fs which is part of the array returned by renderer.resolve() function
  • graceful-fs should be used in the worker thread in order for the problem to appear
1reaction
astoilkovcommented, Oct 6, 2022

Awesome! Thanks, @caoxiemeihao.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Unable to build or serve application that imports @aws/sdk ...
Describe the bug I'm trying to migrate React application from CRA to Vite, but experience errors serving and building application.
Read more >
Laravel Vite build error: 'resolve' is not exported by __vite ...
For this, when I run npm run build , I get the following error. > 'resolve' is not exported by __vite-browser-external, imported by...
Read more >
Vite build failed on project with aws-sdk - DEV Community ‍ ‍
Vite work greate on local development. But I got this error when build. 'request' is not exported by __vite-browser-external, ...
Read more >
module has been externalized for browser compatibility
The requested module '/node_modules/googleapis/build/src/index.js?v=9d844668' does not provide an export named 'google'. I've seen in the browser/devtools ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found