jito-labs / jito-ts

Jito Typescript SDK
Other
128 stars 60 forks source link

Cannot find module inside lib #29

Open Bogdalleksss opened 5 months ago

Bogdalleksss commented 5 months ago
image

I trying this fix through remove node_modules and package-lock.json after which run command "npm install", and this not help me.

How to fix it?

wavvdev commented 4 months ago

I am having the same issue as well!

chonbon commented 4 months ago

Same issue now too.

maxwellpepper commented 4 months ago

You need to add the following code to the package.json file inside rpc-websockets node module inside of the package:

"exports": { "./dist/lib/client": "./dist/lib/client.cjs", "./dist/lib/client/websocket": "./dist/lib/client/websocket.cjs", ".": "./dist/index.cjs", "./browser": "./dist/index.browser.cjs" },

Obviously you need to update the destinations and filenames but this should work.

mukul013 commented 2 months ago

I am still having this issue , if someone can share the exact code which need to be updated in the rpc-websockets package.json , that will help.

piesrtasty commented 1 month ago

You need to add the following code to the package.json file inside rpc-websockets node module inside of the package:

"exports": { "./dist/lib/client": "./dist/lib/client.cjs", "./dist/lib/client/websocket": "./dist/lib/client/websocket.cjs", ".": "./dist/index.cjs", "./browser": "./dist/index.browser.cjs" },

Obviously you need to update the destinations and filenames but this should work.

real mvp right here y'all 💯