Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can not import dashevo/dashcore-lib library in react native #255

Open
chidambararajab opened this issue May 13, 2022 · 0 comments
Open

Can not import dashevo/dashcore-lib library in react native #255

chidambararajab opened this issue May 13, 2022 · 0 comments
Labels

Comments

@chidambararajab
Copy link

Steps to Reproduce (for bugs)

  1. Create react native project and run it.
  2. Now, Intsall the dashevo/dashcore-lib and import them.
  3. The error will be displayed in terminal.

Please find the attached screenshot and logs

image

Your Environment

  • Node Version used: 17

Logs:

Error: Unable to resolve module path from /node_modules/bls-signatures/blsjs.js: path could not be found within the project or in these directories:
node_modules

If you are sure the module exists, try these steps:

  1. Clear watchman watches: watchman watch-del-all
  2. Delete node_modules and run yarn install
  3. Reset Metro's cache: yarn start --reset-cache
  4. Remove the cache: rm -rf /tmp/metro-*
    15 |
    16 | var f;f||(f=typeof Module !== 'undefined' ? Module : {});var aa;f.ready=new Promise(function(a){aa=a});var ba={},m;for(m in f)f.hasOwnProperty(m)&&(ba[m]=f[m]);var ca=!1,u=!1,da=!1,ea=!1;ca="object"===typeof window;u="function"===typeof importScripts;da="object"===typeof process&&"object"===typeof process.versions&&"string"===typeof process.versions.node;ea=!ca&&!da&&!u;var w="",fa,ha,ia,ja;

17 | if(da)w=u?require("path").dirname(w)+"/":__dirname+"/",fa=function(a,b){ia||(ia=require("fs"));ja||(ja=require("path"));a=ja.normalize(a);return ia.readFileSync(a,b?null:"utf8")},ha=function(a){a=fa(a,!0);a.buffer||(a=new Uint8Array(a));assert(a.buffer);return a},1<process.argv.length&&process.argv[1].replace(/\/g,"/"),process.argv.slice(2),f.inspect=function(){return"[Emscripten Module object]"};else if(ea)"undefined"!=
| ^
18 | typeof read&&(fa=function(a){return read(a)}),ha=function(a){if("function"===typeof readbuffer)return new Uint8Array(readbuffer(a));a=read(a,"binary");assert("object"===typeof a);return a},"undefined"!==typeof print&&("undefined"===typeof console&&(console={}),console.log=print,console.warn=console.error="undefined"!==typeof printErr?printErr:print);else if(ca||u)u?w=self.location.href:document.currentScript&&(w=document.currentScript.src),_scriptDir&&(w=_scriptDir),0!==w.indexOf("blob:")?w=w.substr(0,
19 | w.lastIndexOf("/")+1):w="",fa=function(a){var b=new XMLHttpRequest;b.open("GET",a,!1);b.send(null);return b.responseText},u&&(ha=function(a){var b=new XMLHttpRequest;b.open("GET",a,!1);b.responseType="arraybuffer";b.send(null);return new Uint8Array(b.response)});var ma=f.print||console.log.bind(console),z=f.printErr||console.warn.bind(console);for(m in ba)ba.hasOwnProperty(m)&&(f[m]=ba[m]);ba=null;var na={"f64-rem":function(a,b){return a%b},"debugger":function(){}},oa;f.wasmBinary&&(oa=f.wasmBinary);
20 | var noExitRuntime;f.noExitRuntime&&(noExitRuntime=f.noExitRuntime);"object"!==typeof WebAssembly&&z("no native wasm support detected");var pa,qa=new WebAssembly.Table({initial:744,maximum:744,element:"anyfunc"}),ra=!1;function assert(a,b){a||x("Assertion failed: "+b)}var sa="undefined"!==typeof TextDecoder?new TextDecoder("utf8"):void 0;
at ModuleResolver.resolveDependency (/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:129:15)
at DependencyGraph.resolveDependency (/node_modules/metro/src/node-haste/DependencyGraph.js:288:43)
at Object.resolve (/node_modules/metro/src/lib/transformHelpers.js:129:24)
at resolve (/node_modules/metro/src/DeltaBundler/traverseDependencies.js:396:33)
at /node_modules/metro/src/DeltaBundler/traverseDependencies.js:412:26
at Array.reduce ()
at resolveDependencies (/node_modules/metro/src/DeltaBundler/traverseDependencies.js:411:33)
at processModule (/node_modules/metro/src/DeltaBundler/traverseDependencies.js:140:31)
at runMicrotasks ()
at processTicksAndRejections (node:internal/process/task_queues:96:5)
BUNDLE ./index.js

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

No branches or pull requests

1 participant