File tree Expand file tree Collapse file tree 3 files changed +7
-3
lines changed
Expand file tree Collapse file tree 3 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,8 @@ module.exports = {
44 '@babel/preset-env' ,
55 {
66 targets : { node : 'current' } ,
7+ // Ensure ESM in node_modules is converted to CommonJS for Jest
8+ modules : 'commonjs' ,
79 } ,
810 ] ,
911 ] ,
Original file line number Diff line number Diff line change @@ -11,7 +11,9 @@ const config: Config = {
1111 '^.+\\.(ts|tsx)$' : [ 'ts-jest' , { tsconfig : { jsx : 'react-jsx' } } ] ,
1212 '^.+\\.(js|mjs)$' : 'babel-jest' ,
1313 } ,
14- // Allow transforming specific ESM packages in node_modules
14+ // Allow transforming specific ESM packages in node_modules that ship untranspiled ESM.
15+ // @primer /* libraries rely on lit and @lit-labs/react internally for some components.
16+ // We also include GitHub web components that ship ESM-only builds.
1517 transformIgnorePatterns : [
1618 'node_modules/(?!(?:@primer/react|@primer/primitives|@primer/octicons-react|@lit-labs/react|lit|@github/relative-time-element|@github/tab-container-element)/)' ,
1719 ] ,
@@ -26,4 +28,4 @@ const config: Config = {
2628 modulePathIgnorePatterns : [ '<rootDir>/build' , '<rootDir>/node_modules' ] ,
2729} ;
2830
29- module . exports = config ;
31+ export default config ;
Original file line number Diff line number Diff line change 141141 "*" : " biome check --fix --no-errors-on-unmatched" ,
142142 "*.{js,ts,tsx}" : " pnpm test --findRelatedTests --passWithNoTests --updateSnapshot"
143143 }
144- }
144+ }
You can’t perform that action at this time.
0 commit comments