<cards> element

cards element is a container of multiple Card. It can be used as a root element of a TokenScript File.

It can only contain <card> elements.

Basic structure of cards and views

This shows the structure where 3 cards are defined, each of different types, each with its own view and item-view

<ts:cards>
     <ts:card type="action" name="convert-to-xdAI">
          <view>…</view>
          <item-view>…</item-view>
      </ts:card>
      <ts:card type="token" name="main">
          <view>…</view>
          <item-view>…</item-view>
      </ts:card>
      <ts:card type="activity" name="OwnerApproved">
          <view>…</view>
          <item-view>…</item-view>
      </ts:card>
</ts:cards>

Related information

Card

Token Card

ActionCard

ActivityCard

We make tokens smart

Smart Token Labs is the creator of TokenScript and AlphaWallet two open source solutions for a tokenized future.