Files
Dustin ByrneandGitHub 3f6b203022 fix: make @posthog/next importable in Node ESM environments (#3428)
* fix(next): publish node-esm-safe imports

* test(next): guard published esm specifiers
2026-04-23 19:20:48 +00:00

17 lines
485 B
JavaScript

/** @type {import('jest').Config} */
export default {
testEnvironment: 'jsdom',
transform: {
'^.+\\.tsx?$': ['ts-jest', { tsconfig: 'tsconfig.json' }],
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
moduleNameMapper: {
'^(\\.{1,2}/.*)\\.js$': '$1',
},
testMatch: ['<rootDir>/tests/**/*.test.{ts,tsx}'],
collectCoverage: true,
coverageDirectory: 'coverage',
clearMocks: true,
setupFilesAfterEnv: ['./tests/setup.ts'],
}