Skip to content

Commit

Permalink
fix: compatible with miniprogram
Browse files Browse the repository at this point in the history
"can't find variable removeEventListener" in miniprogram
  • Loading branch information
最刚 committed Oct 27, 2021
1 parent 17b8f93 commit 5c3204a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utils/web-preset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const onDocumentEvent = hasDocument
? document.addEventListener.bind(document)
: noop
const offWindowEvent =
hasWindow && window.removeEventListener ? removeEventListener : noop
hasWindow && window.removeEventListener ? window.removeEventListener : noop
const offDocumentEvent = hasDocument
? document.removeEventListener.bind(document)
: noop
Expand Down

0 comments on commit 5c3204a

Please sign in to comment.