fix issue $el is not defined