Linux unitednationsplay.com 3.10.0-1160.45.1.el7.x86_64 #1 SMP Wed Oct 13 17:20:51 UTC 2021 x86_64
nginx/1.20.1
Server IP : 188.130.139.92 & Your IP : 3.16.24.18
Domains :
Cant Read [ /etc/named.conf ]
User : web
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
home /
www /
wb /
node_modules /
fs-extra /
docs /
Delete
Unzip
Name
Size
Permission
Date
Action
copy-sync.md
1.43
KB
-rw-rw-r--
2022-08-30 11:49
copy.md
1.81
KB
-rw-rw-r--
2022-08-30 11:49
emptyDir-sync.md
393
B
-rw-rw-r--
2022-08-30 11:49
emptyDir.md
625
B
-rw-rw-r--
2022-08-30 11:49
ensureDir-sync.md
394
B
-rw-rw-r--
2022-08-30 11:49
ensureDir.md
580
B
-rw-rw-r--
2022-08-30 11:49
ensureFile-sync.md
480
B
-rw-rw-r--
2022-08-30 11:49
ensureFile.md
672
B
-rw-rw-r--
2022-08-30 11:49
ensureLink-sync.md
428
B
-rw-rw-r--
2022-08-30 11:49
ensureLink.md
636
B
-rw-rw-r--
2022-08-30 11:49
ensureSymlink-sync.md
468
B
-rw-rw-r--
2022-08-30 11:49
ensureSymlink.md
677
B
-rw-rw-r--
2022-08-30 11:49
move-sync.md
511
B
-rw-rw-r--
2022-08-30 11:49
move.md
832
B
-rw-rw-r--
2022-08-30 11:49
outputFile-sync.md
729
B
-rw-rw-r--
2022-08-30 11:49
outputFile.md
1
KB
-rw-rw-r--
2022-08-30 11:49
outputJson-sync.md
617
B
-rw-rw-r--
2022-08-30 11:49
outputJson.md
898
B
-rw-rw-r--
2022-08-30 11:49
pathExists-sync.md
174
B
-rw-rw-r--
2022-08-30 11:49
pathExists.md
643
B
-rw-rw-r--
2022-08-30 11:49
readJson-sync.md
797
B
-rw-rw-r--
2022-08-30 11:49
readJson.md
1.18
KB
-rw-rw-r--
2022-08-30 11:49
remove-sync.md
299
B
-rw-rw-r--
2022-08-30 11:49
remove.md
603
B
-rw-rw-r--
2022-08-30 11:49
writeJson-sync.md
495
B
-rw-rw-r--
2022-08-30 11:49
writeJson.md
736
B
-rw-rw-r--
2022-08-30 11:49
Save
Rename
# readJsonSync(file, [options]) Reads a JSON file and then parses it into an object. `options` are the same that you'd pass to [`jsonFile.readFileSync`](https://github.com/jprichardson/node-jsonfile#readfilesyncfilename-options). **Alias:** `readJSONSync()` - `file` `<String>` - `options` `<Object>` ## Example: ```js const fs = require('fs-extra') const packageObj = fs.readJsonSync('./package.json') console.log(packageObj.version) // => 2.0.0 ``` --- `readJsonSync()` can take a `throws` option set to `false` and it won't throw if the JSON is invalid. Example: ```js const fs = require('fs-extra') const file = '/tmp/some-invalid.json' const data = '{not valid JSON' fs.writeFileSync(file, data) const obj = fs.readJsonSync(file, { throws: false }) console.log(obj) // => null ```