Skip to content

Commit

Permalink
Fix rrdom build
Browse files Browse the repository at this point in the history
  • Loading branch information
Juice10 committed Dec 4, 2023
1 parent 2c8ecbe commit 693b5b0
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/rrdom-nodejs/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@
},
{
"path": "../rrweb-snapshot"
},
{
"path": "../types"
}
]
}
10 changes: 10 additions & 0 deletions packages/rrdom/jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,14 @@
export default {
preset: 'ts-jest',
testEnvironment: 'node',
setupFiles: ['./jest.setup.ts'],
/**
* Keeps old (pre-jest 29) snapshot format
* its a bit ugly and harder to read than the new format,
* so we might want to remove this in its own PR
*/
snapshotFormat: {
escapeString: true,
printBasicPrototype: true,
},
};
3 changes: 3 additions & 0 deletions packages/rrdom/jest.setup.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import { TextEncoder, TextDecoder } from 'util';

Object.assign(global, { TextDecoder, TextEncoder });

0 comments on commit 693b5b0

Please sign in to comment.