Year in review card

An individual or a company does this once a year. You have a year, a handful of stat lines, and a closing note. Next year you will want the same card with new numbers, not a new design argument.

This is annual work. The design decision gets made once. This year’s export is this year’s file. Next year is a new file and the same component. December should not reopen the layout.

The job is one component and a { year, stats: [], note } file. One year, one file, one run.

Give Lerret a React component under .lerret/ and optional data. export writes a PNG. Same component, data swapped. There is no batch product, no queue, no orchestrator.

The component is .lerret/personal/year-review.jsx. It shows the year, a handful of stat lines, and a closing note. The stats are an array the component maps over. Three lines or six, the layout is the component’s problem. The note is a field.

Data is { year, stats: [], note }. Pass it with --data. One year, one file, one run. You are not bulk-exporting a decade unless you re-run with each year’s file. Keep last year’s file if you want last year’s card again. That is bulk pattern 1 if you keep a file per year.

The image is a PNG 1200×1500, the shipped year-review size. Portrait card. One image for the year.

You use Lerret because next year is the same component with a new data file. The design decision gets made once. The stats are an array. Adding a line is adding an element, not nudging a text box around last year’s layout. A design file you reopen every December puts the design argument back on the table.

That is the first of the four bulk patterns: re-run export with a different --data file each time. Same components, new values, new images. --data applies to every artboard in the run and is never written back into .lerret/. Next year is the same component with a new data file. The design decision gets made once.

npx @lerret/cli@latest export --data

Pass the year’s file. Start a project with npx create-lerret@latest. More in the use cases index.

--data applies to the run and is never written back into .lerret/. The list is stills from local files. Next year you keep the component and swap the file.

The shipped year-review size is 1200×1500. Year, a handful of stat lines, a closing note. The design decision gets made once.