root-component helper fn.