Error with imports

Why is CoinQuantityLike used as a type but not exported? (Apparently, the code doesn’t throw an error.)


Hey @miguel this is because this type is primarily used internally for working with transaction calls and with our tests. But maybe it should be exported, could you please state your use case and a code snippet?

Nothing special. Currently, I’m working on an issue, and after #2408, my VSCode throws an import error.

Hey @miguel, how are you?

The type CoinQuantityLike is exported from fuels.

As you can see, is being imported from fuels here.

The changes made at #2408 were released only about 3 hours ago. Were you using fuels from the master branch?

What issue are you experiencing?

Hey @Torres-ssf, I’m doing well! How about you?

When I open the file, it throws an error like this:

Cannot find name 'CoinQuantityLike'.
Cannot find name 'ExcludeResourcesOption'.

This just popped up recently, so I find it a bit strange.

1 Like

Have you tried to install dependencies and rebuild the project after getting the latest changes from master?

pnpm install & pnpm build

If that does not work try:

git clean -fdx & pnpm install & pnpm build
1 Like

None of them work. I tried both.

Hey @miguel,

Have you tried the following?

1 Like

Yes, @p.s . I tried.

@miguel do you mean that the imports are not present in the file?

→ Does the following fix your issue?

1 Like

@p.s, I believe yes. Let’s try.