Organize defcomponent macro

This should be a little easier to follow and better organization