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
{{ message }}
This repository has been archived by the owner on Feb 12, 2024. It is now read-only.
Error: Uncaught ReferenceError: global is not defined at node_modules/randombytes/browser.js (browser.js:16:14)
Code bug in randombytes browser.js line 16 var crypto = global.crypto || global.msCrypto
Browser does not have variable "global"
Steps to reproduce the error:
Run code import * as IPFS from "ipfs-core"; in browser
The text was updated successfully, but these errors were encountered:
Thank you for submitting your first issue to this repository! A maintainer will be here shortly to triage and review.
In the meantime, please double-check that you have provided all the necessary information to make this process easy! Any information that can help save additional round trips is useful! We currently aim to give initial feedback within two business days. If this does not happen, feel free to leave a comment.
Please keep an eye on how this issue will be labeled, as labels give an overview of priorities, assignments and additional actions requested by the maintainers:
"Priority" labels will show how urgent this is for the team.
"Status" labels will show if this is ready to be worked on, blocked, or in progress.
"Need" labels will indicate if additional input or analysis is required.
Please open an issue against randombytes - that is where the error is coming from, though I think you may need to shim window.global = window.globalThis in your vue config somehow.
ipfs-core:"0.18.0"
chrome 113.0.5672.127
randombytes browser.js
Severity:
High
Description:
Vue code:
`<script setup lang="ts">
import * as IPFS from "ipfs-core";
const ipfslog = async () => {
const ipfs = await IPFS.create();
const { cid } = await ipfs.add("Hello world");
console.log(await ipfs.version())
console.info(cid);
};
</script>
Error:
Uncaught ReferenceError: global is not defined at node_modules/randombytes/browser.js (browser.js:16:14)
Code bug in randombytes browser.js line 16
var crypto = global.crypto || global.msCrypto
Browser does not have variable "global"
Steps to reproduce the error:
Run code
import * as IPFS from "ipfs-core";
in browserThe text was updated successfully, but these errors were encountered: