I think it'd be better to do the deletion at the start of the `gen_component_html` task instead.