This repository was archived by the owner on Feb 12, 2024. It is now read-only.
This repository was archived by the owner on Feb 12, 2024. It is now read-only.
error: Could not resolve "electron" when using in a web app #4011
Closed
Description
Hi I get the following in a vite/vue app when i import ipfs
Pre-bundling dependencies:
vue
anchorme
ipfs-core
(this will be run only when your dependencies or config have changed)
> node_modules/electron-fetch/lib/index.es.js:1257:21: error: Could not resolve "electron" (mark it as external to exclude it from the bundle, or surround it with try/catch to handle the failure at run-time)
1257 │ electron = require('electron');
It only happens when I import ipfs but I am confused why electron would be involved at all in this situation.
I have seen people use ipfs fine in react (web) apps