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 uniqid in vite project and typescript show error Uncaught Error: Module "os" has been externalized for browser compatibility. Cannot access "os.networkInterfaces" in client code.
#45
Open
gradyll opened this issue
Jul 16, 2022
· 2 comments
when i import uniqid,it show this error:"Uncaught Error: Module "os" has been externalized for browser compatibility. Cannot access "os.networkInterfaces" in client code."
Why?
The text was updated successfully, but these errors were encountered:
I just ran into this issue as well, and looks like that's because this package only exports CommonJS module format, and Vite doesn't polyfill those by default:
I'm going to be looking for an ESM-compatible alternative personally.
when i import uniqid,it show this error:"Uncaught Error: Module "os" has been externalized for browser compatibility. Cannot access "os.networkInterfaces" in client code."
Why?
The text was updated successfully, but these errors were encountered: