Why sway doesn't recognize the standard src20 library?

hi, im having problems wen i try use the SRC20 as value in a event variable

the import be success but the compiler says that it doesn’t recognize the type

here u have my code image and the issue image


Hi @andrwmayorca ,

Please provide the results of fuelup show first so we can see what versions you are on.

Secondly, can you provide the entire code sample, gist or public github repo for us tor review.

Note, as of recent, the sway-standards changed its module design such that the right module path should be: use standards::src20::SRC20:

Hope this helps.

1 Like

right now I’m using the beta-4 toolchain

1 Like

can you try updating to the latest toolchain please.

its done! and I still having the same issue

try going through this doc:
Sway Standards | Fuel Docs

There is a Native Asset example contract which you shough try to compile and use as a template for your project.

@andrwmayorca

Are you still stuck here? If so, can you provide the results of fuelup show first.