we recently migrated to Sitecore 9.1 from 8.1 and we see a bunch of JS errors on the page only in experience editor mode. I dont see them happening in the normal mode.
I tried replacing the Sitecore vanilla js files - still the same.
there are two majors errors that I see getting repeated all over :
Uncaught TypeError: Cannot read property 'hide' of undefined
and
Uncaught TypeError: Cannot read property 'replace' of undefined
Any idea why this might happen?