代码如下:
let path = "./plays.json";
let fs = require('fs');
let plays = JSON.parse(fs.readFileSync(path));
console.log(plays);
代码如下:
let path = "./plays.json";
let fs = require('fs');
let plays = JSON.parse(fs.readFileSync(path));
console.log(plays);