79447966

Date: 2025-02-18 10:54:29
Score: 2
Natty:
Report link

Better use package jest-fixed-jsdom, this solves the problem of nodejs globals.

npm i jest-fixed-jsdom

Then update jest.config.js

module.exports = {
  testEnvironment: 'jest-fixed-jsdom',
}

You can read more about this here https://mswjs.io/docs/faq/#requestresponsetextencoder-is-not-defined-jest

Reasons:
  • Probably link only (1):
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: suraj patil