找不到模块,尽管文件夹位于src目录内部,但在SRC目录错误事件之外
我正在在React JS中的一个组件中导入智能合约的ABI。而且这个错误即将出现。尽管合同ABI“伪像”文件夹位于SRC目录内。这个错误如何发生?
Module not found: Error: You attempted to import ../../../../artifacts/contracts/cont.sol/VerifySig.json which falls outside of the project src/ directory. Relative imports outside of src/ are not supported.
You can either move it inside src/, or add a symlink to it from project's node_modules/.
i am importing the abi of smart contract inside one component in react js. and this error is coming up. although the contract abi "artifacts" folder is inside of the src directory. how is this error coming up possible?
Module not found: Error: You attempted to import ../../../../artifacts/contracts/cont.sol/VerifySig.json which falls outside of the project src/ directory. Relative imports outside of src/ are not supported.
You can either move it inside src/, or add a symlink to it from project's node_modules/.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论