I am trying to store the values of state variables inside a json file after creating it but am facing lot of error because using fs in next.js, can someone please tell me the mistake here...
[Here's the complete code][https://i.stack.imgur.com/XipP4.jpg]