File size: 271 Bytes
3bd5401
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
const fs = require("fs");
try
{
    let json = fs.readFileSync("ShareGPT_V4_unfiltered_cleaned_split.json", "utf8");
	var obj = JSON.parse(json);
	console.log("No problem");
}
catch (e) {
    // The JSON was invalid, `e` has some further information
    console.log(e);
}