Skip to content

Commit 12b55ad

Browse files
Copilotmoufmouf
andcommitted
Address code review feedback: improve nextTick polyfill and remove redundant dep
Co-authored-by: moufmouf <1290952+moufmouf@users.noreply.github.com>
1 parent 35f61fb commit 12b55ad

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

test/setup-browser.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@ import { Buffer } from 'buffer'
1010
// Ensure process.nextTick is available
1111
if (!process.nextTick) {
1212
process.nextTick = function(fn: Function, ...args: any[]) {
13-
Promise.resolve().then(() => fn(...args))
13+
return Promise.resolve().then(() => fn(...args))
1414
}
1515
}

vitest.browser.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ export default defineConfig({
1717
}
1818
},
1919
optimizeDeps: {
20-
include: ['events', 'buffer', 'stream-browserify', 'util', 'process', 'process/browser']
20+
include: ['events', 'buffer', 'stream-browserify', 'util', 'process/browser']
2121
},
2222
test: {
2323
globals: true,

0 commit comments

Comments
 (0)