refactoring
implement component registry