Small modification. Auto detect component.json