Package Exports
- jest-kdu-preprocessor
- jest-kdu-preprocessor/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (jest-kdu-preprocessor) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
jest-kdu-preprocessor
This package supports both ES6 (Babel) and TypeScript.
Portions both preprocessors are heavily based kduify (Copyright (c) 2021-present NKDuy).
Installation
- add package you your project
yarn add --dev jest-kdu-preprocessor
ornpm install --saveDev jest-kdu-preprocessor
modify package.json's jest section by adding/editing moduleFileExtensions and transform properites:
"jest": { "moduleFileExtensions": [ "js", "kdu" ], "transform": { "^.+\\.js$": "<rootDir>/node_modules/babel-jest", ".*\\.(kdu)$": "<rootDir>/node_modules/jest-kdu-preprocessor" } }
Start writing test that can import
*.kdu
components - see example ./tests/index.spec.jsProfit!