string-replace-unexpected-behavior:这是一个错误吗?

时间:2024-06-07 00:35:26
【文件属性】:

文件名称:string-replace-unexpected-behavior:这是一个错误吗?

文件大小:3.98MB

文件格式:ZIP

更新时间:2024-06-07 00:35:26

JavaScript

string#replace()意外行为 描述 // Prepare. const assert = require ( "assert" ) const fs = require ( "fs" ) const S = fs . readFileSync ( "S.txt" , "utf8" ) const A = fs . readFileSync ( "A.txt" , "utf8" ) const B = fs . readFileSync ( "B.txt" , "utf8" ) assert ( ! A . includes ( "\n" ) , "A doesn't include line breaks." ) assert ( ! B . includes ( "\n" ) , "B doesn't include line breaks." ) // Main. con


【文件预览】:
string-replace-unexpected-behavior-master
----S.txt(11.82MB)
----R.txt(12.35MB)
----LICENSE(1KB)
----A.txt(22B)
----test.js(442B)
----README.md(920B)
----B.txt(515KB)

网友评论