Uncaught TypeError: Cannot read property ‘match’ of null出现这个错误的原因是object为null,像下面这样判断一下,就可以解决。 if(object){ object.match("123"); }