@react-native-esbuild/jest
TypeScript icon, indicating that this package has built-in type declarations

0.1.0-alpha.43 • Public • Published

@react-native-esbuild/jest

react-native preset for jest powered by @react-native-esbuild

Usage

exports.default = {
  preset: 'react-native',
  transform: {
    '^.+\\.(t|j)sx?$': '@react-native-esbuild/jest',
  },
};

// With transformer options(for enable custom instrument).
exports.default = {
  preset: 'react-native',
  transform: {
    '^.+\\.(t|j)sx?$': ['@react-native-esbuild/jest', /* TransformerConfig */],
  },
};
/**
 * @see {@link https://github.com/kwonoj/swc-plugin-coverage-instrument}
 */
interface TransformerConfig {
  experimental?: {
    customCoverageInstrumentation?: {
      coverageVariable?: string;
      compact: boolean;
      reportLogic: boolean;
      ignoreClassMethods: string[];
      instrumentLog?: {
        level: string;
        enableTrace: boolean;
      };
    };
  };
}

Package Sidebar

Install

npm i @react-native-esbuild/jest

Weekly Downloads

0

Version

0.1.0-alpha.43

License

MIT

Unpacked Size

14.3 kB

Total Files

12

Last publish

Collaborators

  • ghlee