querystring.escape(str)


querystring.escape() 方法以针对网址查询字符串的特定要求优化的方式对给定的 str 执行网址百分比编码。

¥The querystring.escape() method performs URL percent-encoding on the given str in a manner that is optimized for the specific requirements of URL query strings.

querystring.escape() 方法被 querystring.stringify() 使用,通常不会被直接使用。导出它主要是为了允许应用代码在必要时通过将 querystring.escape 分配给替代函数来提供替换的百分比编码实现。

¥The querystring.escape() method is used by querystring.stringify() and is generally not expected to be used directly. It is exported primarily to allow application code to provide a replacement percent-encoding implementation if necessary by assigning querystring.escape to an alternative function.