What a composition controls
A composition brings three things together:- content — text, shapes, images, video, audio, or another composition;
- time — when each part starts and how long it remains;
- motion — seekable animation tied to the same playhead.
When to create another composition
Separate a part when it has a clear job and can be understood on its own. Good boundaries include:- a complete scene;
- a repeated title or caption treatment;
- a product-demo sequence;
- a visual reused in several places;
- a complex section that is easier to review separately.
How nesting works
The main composition gives each nested composition a place on its timeline:data-composition-src paths resolve from the project root, even when the referencing composition is inside another folder.
This tells HyperFrames to mount product-demo.html at four seconds and show a six-second window of it. The nested source keeps its own content and animation.
If the same source is mounted more than once, each instance can start at a different time or receive different variables.
Decide where to make a change
- Edit the nested composition when the scene itself should change everywhere it is used.
- Edit the main composition when only its placement, duration, or relationship to other scenes should change.
- Ask the agent when a revision changes the story or crosses several compositions.