UNPKG

1.06 kBMarkdownView Raw
1# @availity/workflow-plugin-react
2
3> Plugin for React based availity-workflow boilerplate projects
4
5- Webpack 4 [https://webpack.js.org/](https://webpack.js.org/)
6- Babel [https://babeljs.io/](https://babeljs.io/)
7- Jest [https://facebook.github.io/jest/](https://facebook.github.io/jest/)
8
9## Testing Libraries
10
11By default `@testing-library/react` and `jest-dom` are added to the project. Some of their scripts are also automatically added to the `setUpFilesAfterEnv` param for jest [here](./test.js#42).
12
13- `@testing-library/react/cleanup-after-each` - Will clean up the DOM after each test has ran.
14- `jest-dom/extend-expect` - Custom jest matchers that you can use to extend jest
15
16If you want to override this you can create a file in the `/app` directory called `jest.init.js` and export whichever modules you want.
17
18#### Example
19```javascript
20module.exports = [
21 '@testing-library/react/cleanup-after-each',
22 'jest-dom/extend-expect'
23]
24```
25
26More Info on Jest `setUpFilesAfterEnv` [here](https://jestjs.io/docs/en/configuration#setupfilesafterenv-array)