The erros occurs when i add const replace = require("replace-in-file"); in file to my code
const replace = require("replace-in-file");
const options = {
files: "./config/dashboardData.json",
configFile: true,
from: /}\n{/g,
to: ",\n",
};
I have installed babel and configured the preset still I got the issue
The package
replace-in-file
handles files on the OS, so it needs to be called from Node.You would need to set up a Cypress task.
In Cypress ver 10+, do this in
cypress.config.js