class {
    onMount() {
        this.events = [];
    }
}

<div>
    <ul>
        <for(color in input.colors)>
            <li key=color on-detach('handleDetach', color)>
                ${color}
            </li>
        </for>
    </ul>
</div>