rarible / sdk

MIT License
83 stars 43 forks source link

Import error: Can't resolve aptos-labs/ts-sdk #648

Open kasper-keunen opened 1 month ago

kasper-keunen commented 1 month ago

When i add the package to my dapp and impoort 'createRaribleSdk' immediatly upon building i get the following error:

./node_modules/@rarible/aptos-sdk/build/balance/balance.js:5:0
Module not found: Can't resolve '@aptos-labs/ts-sdk'

https://nextjs.org/docs/messages/module-not-found

Import trace for requested module:
./node_modules/@rarible/aptos-sdk/build/index.js
./node_modules/@rarible/sdk/build/sdk-blockchains/aptos/index.js
./node_modules/@rarible/sdk/build/index.js
./app/mint/_components/ContractDemo.tsx
./app/mint/page.tsx

Pretty much following the steps in the docs: https://docs.rarible.org/reference/getting-started. Is this a bug? Can't imagine as i literally did nothing else than install the package and import a function?

Screenshot 2024-07-22 at 18 20 18
ex1st0r commented 1 month ago

Update sdk to latest version and try again, should work

kasper-keunen commented 1 month ago

I tried this yesterday? Was this fixed since then? Will give it a try - i got this to work by manually installing the missing packages.