All motions
Code · Motion for React

Code folding

A block collapses to a summary line and expands back with correct height.

Live preview

function total(items) {
return items.reduce((a, b) => a + b, 0);
}

Copy the prompt

Ask for it in plain words

Let a code block collapse into a single summary line and expand back out, animating the height smoothly.

Need both prompts plus the metadata in one file?