See It In Action

Try the interactive demo below!

tamagotchi-demo.tsx
const
pet = useTamagotchi();

// Your pet evolves as you code!
useEffect
(() => {{ '{' }}
pet.{{ codeAction() }}();
{{ codeComment() }}
{{ '}' }}, []);
{{ stageName() }}
@if (currentSprite()) {
}
{{ mood() }}
🍖
😊

The Evolution Journey

@for (stage of stages(); track stage.name; let i = $index) {
{{ stage.name }}
{{ stage.ticks }}
@if (i < stages().length - 1) {
} }