Skip to content
This repository has been archived by the owner on Jan 12, 2024. It is now read-only.

Vue example #35

Closed
colem213 opened this issue Sep 10, 2021 · 6 comments
Closed

Vue example #35

colem213 opened this issue Sep 10, 2021 · 6 comments

Comments

@colem213
Copy link

I'm getting these errors when trying to run the browser-vue example:

 ERROR  Failed to compile with 2 errors                                                                                              3:08:46 AM

 error  in ./node_modules/levelup/lib/levelup.js

Module not found: Error: Can't resolve 'util' in '/workspaces/js-ipfs-examples/examples/browser-vue/node_modules/levelup/lib'

BREAKING CHANGE: webpack < 5 used to include polyfills for node.js core modules by default.
This is no longer the case. Verify if you need this module and configure a polyfill for it.

If you want to include a polyfill, you need to:
        - add a fallback 'resolve.fallback: { "util": require.resolve("util/") }'
        - install 'util'
If you don't want to include a polyfill, you can use an empty module like this:
        resolve.fallback: { "util": false }

 error  in ./node_modules/libp2p-kad-dht/src/routing-table/index.js

Module not found: Error: Can't resolve './generated-prefix-list.json' in '/workspaces/js-ipfs-examples/examples/browser-vue/node_modules/libp2p-kad-dht/src/routing-table'
@pfnsec
Copy link

pfnsec commented Sep 12, 2021

I'm also running into this... Any resolution?

@oliveriosousa
Copy link
Contributor

Hi @colem213 and @pfnsec

Yes, this has been fixed libp2p/js-libp2p-kad-dht@3c737c1

Sorry for the late response.

@achingbrain
Copy link
Contributor

@oliveriosousa
Copy link
Contributor

The error showed is fixed but still fails to build.

See #42

@achingbrain
Copy link
Contributor

This should be fixed by webpack/enhanced-resolve#304

@oliveriosousa
Copy link
Contributor

oliveriosousa commented Sep 21, 2021

This issue has been fixed webpack/enhanced-resolve#304
PR (merged): webpack/enhanced-resolve#305

Please, run yarn clean in the root of the project and do a clean install yarn install

Sorry for the late response, let me know if you still get some erros

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants