change from using plugin method to component