Deno.readfilesync
readFileSync
- 
readFileSync(path: string): Uint8Array 
- 
同步地读取并将文件的全部内容解析为字节数组。 TextDecoder可以在需要的情况下可以将字节转换成字符串。 读取目录返回一个空的数据数组。Synchronously reads and returns the entire contents of a file as an array of bytes. TextDecodercan be used to transform the bytes to string if required. Reading a directory returns an empty data array.const decoder = new TextDecoder("utf-8"); const data = Deno.readFileSync("hello.txt"); console.log(decoder.decode(data));需要 allow-read权限。Requires allow-readpermission.
参数
-   ##### path: string
 
                             
                             
                             
                            