UNPKG

dts-cli

Version:

Zero-config TypeScript package development

25 lines (24 loc) 939 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.createJestConfig = void 0; const utils_1 = require("./utils"); function createJestConfig(_, rootDir) { const config = { transform: { '.(ts|tsx)$': (0, utils_1.resolve)('ts-jest'), '.(js|jsx)$': (0, utils_1.resolve)('babel-jest'), // jest's default }, transformIgnorePatterns: ['[/\\\\]node_modules[/\\\\].+\\.(js|jsx)$'], moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json', 'node'], collectCoverageFrom: ['src/**/*.{ts,tsx,js,jsx}'], testMatch: ['<rootDir>/**/*.(spec|test).{ts,tsx,js,jsx}'], testEnvironmentOptions: { testURL: 'http://localhost' }, rootDir, watchPlugins: [ 'jest-watch-typeahead/filename', 'jest-watch-typeahead/testname', ], }; return config; } exports.createJestConfig = createJestConfig;