Lists
Lists hold items you reuse across snippets. Keep them in one place and every snippet that uses them stays up to date.
There are two ways to use a list:
- Pick an item: Countries, environments, product names. The fill-in form shows a searchable picker.
- Use each item once: Promo codes, license keys, invite links. Typefu takes the next unused item and marks it used, so you never hand out the same one twice.
Create a list
- Open Building Blocks ▸ Lists.
- Click New List and give it a name, for example
Countries. - Choose a Source:
- Items below: Paste items in with Add, one per line. Duplicates are skipped.
- CSV file: A file like
~/Documents/countries.csv. Turn on First row is a header if it has one. - JSON file
- Shell command: Each line of the output is an item, for example
ls ~/Projects.
Use it in a snippet:
Shipping to {list name="Countries"}Use each item once
Turn on Use Each Item Once for a list of codes. The list shows how many items are still available.
Thanks for your support! Here's your code: {list name="Promo" take=1}take=1takes the next unused item and marks it used. Usetake=3to take three.- While the fill-in form is open, the item is held for you. Cancel, and it goes back to the list.
- Once inserted, the item stays used. Select it in the list and click Mark Unused to put it back.
- The fill-in form shows how many items are left.
Add items from anywhere
Select lines of text in any app and choose Add to List in the action menu. Each line becomes an item.