Modules and blocks

The sidebar lists modules. Each module is built on a block, the reusable screen underneath it. Knowing the difference is what lets you add your own modules: most new modules are a new use of a block you already have, so they need no new code.

The words

WordWhat it meansExample
ModuleWhat the sidebar lists: one use of a block, with its own name and data fileTasks, People, Accounts
BlockThe reusable screen and data shape a module is built fromdatatable
ComponentA small interface piece inside a blockA button, a table, a dialog
ViewHow a datatable module shows its rowstable, task or goal
Settings pageA page in Settings; each module has oneSettings → Tasks

Blocks are named for their shape, modules for their purpose, so the two never share a name.

The blocks and the modules on them

BlockWhat it givesModules on it
profileOne page about youAbout
datatableRows with columns you define, in a table, task or goal viewTasks, People, Goals, and your own
pagesMarkdoc pages in a tree, with a reader. Built into the app, so it has no folder in app/src/blocks/Wiki

The kit has five modules: About, Goals, Tasks, People and Wiki. A new app gets all five unless you pick fewer on Create. About is always in. A module you left out can be added back later, and one you no longer want can be taken out: ask Claude, and it runs the starta command. There are no templates per job: beyond these five, the modules you add are the ones you build yourself, such as Accounts.

Why Tasks and People share a block

Tasks and People look different, but they are the same block, datatable, used twice:

  • Tasks uses the task view: a checklist you tick off, with due dates and the person each task is waiting on.
  • People uses the table view: a table of names, roles and organisations.

Each has its own name, its own columns and its own data file. The screen code is shared. That is the point of showing them side by side: once you see that Tasks and People are one block, a third module on the same block, such as Accounts, is an obvious next step.

The module file

Each module is one small file in app/src/modules/. Here is People's, without its field list:

{
  "id": "people",
  "title": "People",
  "block": "datatable",
  "view": "table",
  "icon": "users",
  "file": "people.json",
  "order": 20,
  "purpose": "Who you work with, and what to know about each of them.",
  "fields": []
}
KeyWhat it sets
idThe address, /people
titleThe name in the sidebar
blockThe block it is built on
viewFor a datatable: table, task or goal
iconThe sidebar mark; an unknown name gets a default mark
fileIts data file in app/data/
orderIts place in the sidebar, lowest first
purposeOne line, shown on its Settings page
fieldsFor a datatable: its columns and their kinds

The sidebar comes from the module files

The app finds its modules by reading the folder of module files, and builds three things from them: the sidebar, each module's page, and each module's page in Settings. So:

  • Add a module file and a new item appears in the sidebar, with its page and its Settings page.
  • Change title or order and the sidebar changes.
  • Delete the module file and the module disappears. Its data file stays in app/data/ until you decide otherwise.

The kit's modules sit in this order: Tasks 10, People 20, Goals 35, Wiki 60, About 70. About is always last.

A module's Settings page is read-only. It shows the module's name, block, view, data file and fields. To change any of them, ask Claude.

Worked example: Accounts

Sam wants a list of the customer accounts they look after. They ask Claude:

"Build an Accounts module on the datatable block, as a table. Columns: name, plan, renewal date, health, main contact, and a notes tab."

Claude writes two files and no code:

FileHolds
app/src/modules/accounts.jsonThe module: its title, block, view, order and fields
app/data/accounts.jsonSam's rows, starting with Tallow & Co and Harbourline Logistics

Claude opens the new module to check it. Accounts now sits in the sidebar, with its own page and its own Settings page. The datatable block is the same one Tasks and People use.

A module that needs a screen no block offers, such as a board, means changing a block or building a new one. That is a bigger step, covered in Changing a block.