whole_func_string: function destroySync (component, removeNode=true) {
    syncDestructionsInProgressCounter++
    destroyChildComponents(component.virtualNode)
    if (syncDestructionsInProgressCounter === 1 && removeNode) component.element.remove()
    syncDestructionsInProgressCounter--
  }
func_code_string: function destroySync (component, removeNode=true) {
    syncDestructionsInProgressCounter++
    destroyChildComponents(component.virtualNode)
    if (syncDestructionsInProgressCounter === 1 && removeNode) component.element.remove()
    syncDestructionsInProgressCounter--
  }
func_documentation_string: A synchronous version of `destroy`.  Note that we track whether `destroy` calls are in progress and only remove the element if we are not a nested call.