diff --git a/src/createJestConfig.ts b/src/createJestConfig.ts index 2a05fd78c..9a10921df 100644 --- a/src/createJestConfig.ts +++ b/src/createJestConfig.ts @@ -5,11 +5,12 @@ export function createJestConfig( const config = { transform: { '.(ts|tsx)': require.resolve('ts-jest/dist'), + '.(js|jsx)': require.resolve('babel-jest'), // jest's default }, transformIgnorePatterns: ['[/\\\\]node_modules[/\\\\].+\\.(js|jsx)$'], moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json', 'node'], - collectCoverageFrom: ['src/**/*.{ts,tsx}'], - testMatch: ['/**/*.(spec|test).{ts,tsx}'], + collectCoverageFrom: ['src/**/*.{ts,tsx,js,jsx}'], + testMatch: ['/**/*.(spec|test).{ts,tsx,js,jsx}'], testURL: 'http://localhost', rootDir, watchPlugins: [