Closed kkga closed 1 year ago
Hey @kkga, thanks for your report! I've just updated the location in code that you mentioned. I can't easily tell if that already fixes the issue, there might be other occurances of a document reference that are in global scope, I'm not too sure, I'm also not sure if what I did completely fixes the issue, so I might have to look into this deeper if this didn't work.
Can you try it again with the latest version (2.1.3) and let me know if there are still issues?
Can you try it again with the latest version (2.1.3) and let me know if there are still issues?
Sure, I can try it out. Seems like 2.1.2 is still the latest version though.
Didn't expect you to answer this fast, the pipeline is still running, release should be out in a few minutes 😅
Still hitting the same error, but in a different file now:
error - node_modules/.pnpm/react-complex-tree@2.1.3_react@18.2.0/node_modules/react-complex-tree/lib/cjs/hotkeys/useHotkey.js (19:0) @ useHotkey
error - ReferenceError: document is not defined
Looks like there's 2 references to document
in useHotkey.ts
:
Hm okay, I updated a bunch of references of document this time, hopefully this time it doesn't come up again 😅 Can you try again with v2.1.4-alpha.0?
Not seeing the error anymore! Thanks a lot for tackling this 👍🏼
Cool, happy to hear and thanks for your patience!
Describe the bug
Getting an error in NextJS 13 (app directory), which looks very similar to this: https://github.com/vercel/next.js/issues/44014.
Like in the linked issue, the
document
seems to be available to the component as the keyboard shortcuts are working, however I see this output in the terminal console:To Reproduce
I'm finding it hard to reproduce the issue on cloud platforms like codesandbox.
Desktop (please complete the following information):