Skip to content

Commit 1a898ca

Browse files
SimenBthymikee
authored andcommitted
chore: make readme example config be js (#65)
* chore: make readme example config be js * Update README.md Co-Authored-By: SimenB <sbekkhus91@gmail.com>
1 parent 586c4cd commit 1a898ca

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

README.md

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -104,14 +104,13 @@ test('snapshot difference between 2 objects', () => {
104104

105105
...or add it globally to your jest config:
106106

107-
```json
108-
{
109-
"jest": {
110-
"snapshotSerializers": [
111-
"<rootDir>/node_modules/snapshot-diff/serializer.js"
112-
]
113-
}
114-
}
107+
```js
108+
// jest.config.js
109+
module.exports = {
110+
snapshotSerializers: [
111+
require.resolve('snapshot-diff/serializer.js'),
112+
],
113+
};
115114
```
116115

117116
## API

0 commit comments

Comments
 (0)