在typescript中使用escape 和 unescape函数时,报错Cannot find name 'escape'.
![](https://img.haomeiwen.com/i9902292/baed6627d1069eef.png)
解决方法:加上声明 declare function escape(s:string): string;
![](https://img.haomeiwen.com/i9902292/76e7678c90ebd512.png)
在typescript中使用escape 和 unescape函数时,报错Cannot find name 'escape'.
解决方法:加上声明 declare function escape(s:string): string;
本文标题:TypeScript报错找不到方法 escape
本文链接:https://www.haomeiwen.com/subject/nhwqnxtx.html
网友评论