editorjs-undo icon indicating copy to clipboard operation
editorjs-undo copied to clipboard

TypeError: can't access property "type", t[i] is undefined in Next.js

Open eiiot opened this issue 1 year ago • 0 comments

Precheck

  • [x] Do a quick search and make sure the bug has not been reported yet.
  • [x] Please disclose security vulnerabilities privately at [email protected].
  • [x] Finally, be nice and have fun!.

Description

I'm getting a weird error when using this component with NextJS. The page crashes, but is fixed after reloading, and doesn't appear for a while? It seems to be random. Possibly a SSR issue?

Environment

  • Editor.js version: v2.25.0
  • Plugins you use with their versions: DragDrop
  • Device, Browser, OS: MacOS in Firefox

Current behavior

Unhandled Runtime Error

TypeError: can't access property "type", t[i] is undefined
Call Stack
value
node_modules/editorjs-undo/dist/bundle.js (1:6033)
value/<
node_modules/editorjs-undo/dist/bundle.js (1:5490)```

### Expected behavior

The page doesn't crash.

eiiot avatar Sep 29 '22 16:09 eiiot