Wraps components in a closure to make sure it's injected in the global scope.