dfinity / examples

Example applications, microservices, and code samples for the Internet Computer
https://dfinity.org
Apache License 2.0
537 stars 362 forks source link

🎨 rewrote example #722

Closed letmejustputthishere closed 7 months ago

letmejustputthishere commented 7 months ago

Overview Why do we need this feature? What are we trying to accomplish?

The example was outdated.

Requirements What requirements are necessary to consider this problem solved?

Update the dependencies and README.

letmejustputthishere commented 7 months ago

Ideally, I'd say the token transfer example would use ICRC-1 and ICRC-2 interface or what do you think?

i think it's good to have an example for interacting with the ICP ledger standard, but we can create another one to interact with ICRC1 ledgers. i can also add it to this example. what do you prefer?

domwoe commented 7 months ago

i think it's good to have an example for interacting with the ICP ledger standard, but we can create another one to interact with ICRC1 ledgers. i can also add it to this example. what do you prefer?

Makes sense. My preference would be to rename this example to icp_transfer and create a new token_transfer example based on ICRC-1/2. The readme of the first one should also mention that the ICP ledger also supports ICRC-1 and link to the token_transfer example. Please also give a quick heads up to @andreacerulli, since he's listed as the owner of this example.

letmejustputthishere commented 7 months ago

i think it's good to have an example for interacting with the ICP ledger standard, but we can create another one to interact with ICRC1 ledgers. i can also add it to this example. what do you prefer?

Makes sense. My preference would be to rename this example to icp_transfer and create a new token_transfer example based on ICRC-1/2. The readme of the first one should also mention that the ICP ledger also supports ICRC-1 and link to the token_transfer example. Please also give a quick heads up to @andreacerulli, since he's listed as the owner of this example.

should we call this icrc1_transfer instead then?

domwoe commented 7 months ago

should we call this icrc1_transfer instead then?

Although this would be the most precise name, I would keep it at token_transfer, just because newcomers might have no idea what icrc1 is but might look for an example to create or interact with a token. Hence, I'd prefer meeting them at common terminology and then educating them about the standards.

letmejustputthishere commented 7 months ago

@andreacerulli @domwoe i renamed the example and added token_transfer examples in rust and motoko, can you review pls