Skip to content

Commit 210086f

Browse files
committed
cleanup
1 parent f7db30a commit 210086f

1 file changed

Lines changed: 11 additions & 8 deletions

File tree

src/index.ts

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,16 @@ import type { OptionsReceived } from "pretty-format";
55

66
/* istanbul ignore next */
77
if (!process.env.STL_SKIP_AUTO_CLEANUP) {
8-
if (typeof afterEach === 'function') {
8+
if (typeof afterEach === "function") {
99
afterEach(async () => {
10-
await cleanup()
11-
})
10+
await cleanup();
11+
});
1212
// @ts-ignore
13-
} else if (typeof teardown === 'function') {
13+
} else if (typeof teardown === "function") {
1414
// @ts-ignore
1515
teardown(async () => {
16-
await cleanup()
17-
})
16+
await cleanup();
17+
});
1818
}
1919
}
2020

@@ -36,9 +36,12 @@ function render(
3636
): {
3737
container: HTMLElement;
3838
baseElement: HTMLElement;
39-
debug: (baseElement?: HTMLElement | HTMLElement[], maxLength?: number, options?: OptionsReceived) => void;
39+
debug: (
40+
baseElement?: HTMLElement | HTMLElement[],
41+
maxLength?: number,
42+
options?: OptionsReceived
43+
) => void;
4044
unmount: () => void;
41-
asFragment: () => DocumentFragment;
4245
} & { [P in keyof Queries]: BoundFunction<Queries[P]> } {
4346
if (!baseElement) {
4447
// Default to document.body instead of documentElement to avoid output of potentially-large

0 commit comments

Comments
 (0)