I am getting the error below on running the eslint.
\helpers\getEnvCredentials.ts 4:9 error Require statement not part of import statement @typescript-eslint/no-var-requires
✖ 1 problem (1 error, 0 warnings)
That error is referring to these lines of code wherein it is saying that using the "require" statement should be use only on imports. Please see (https://typescript-eslint.io/rules/no-var-requires/) for reference
const dataCredentials = JSON.parse(
JSON.stringify(
require("../fixtures/credentials/" + env + "-credentials.json")
)
);
Is there another way to do that line of codes above that will be accepted by eslint?