Resource by Example

In this section you'll finally learn how to use resources. We'll go through the process of defining a resource and methods to work with it, and in the end you'll get a full contract which you can then use as a template.

We'll create a Collection contract, which will allow us to:

  • start a collection
  • add and take items from collection
  • destroy collection

Let's begin!