tldraw / tldraw

SDK for creating whiteboards and canvas experiences on the web.
https://tldraw.dev
Other
33.04k stars 1.98k forks source link

[Bug]: RTE: TypeError: Cannot read properties of undefined (reading 'currentPageId') #3667

Closed richburdon closed 6 days ago

richburdon commented 2 weeks ago

What happened?

The following error is logged in the browser console when swapping the entire store state (e.g., changing between documents). This started happening in 2.1.4 (migrating from alpha-19).

2react_devtools_backend_compact.js:12714 TypeError: Cannot read properties of undefined (reading 'currentPageId')
    at Editor.getCurrentPageId (@tldraw_tldraw.js?v=3c6a9151:24009:35)
    at __UNSAFE__Computed.__unsafe__getWithoutCapture (chunk-OQBEJPHR.js?v=3c6a9151:745:27)
    at haveParentsChanged (chunk-OQBEJPHR.js?v=3c6a9151:14:22)
    at __UNSAFE__Computed.__unsafe__getWithoutCapture (chunk-OQBEJPHR.js?v=3c6a9151:731:67)
    at haveParentsChanged (chunk-OQBEJPHR.js?v=3c6a9151:14:22)
    at __UNSAFE__Computed.__unsafe__getWithoutCapture (chunk-OQBEJPHR.js?v=3c6a9151:731:67)
    at haveParentsChanged (chunk-OQBEJPHR.js?v=3c6a9151:14:22)
    at __UNSAFE__Computed.__unsafe__getWithoutCapture (chunk-OQBEJPHR.js?v=3c6a9151:731:67)
    at haveParentsChanged (chunk-OQBEJPHR.js?v=3c6a9151:14:22)
    at __EffectScheduler__.maybeScheduleEffect (chunk-OQBEJPHR.js?v=3c6a9151:387:33) '\n    at SketchComponent (

https://github.com/tldraw/tldraw/assets/3523355/e769147c-e0a8-4f1e-baee-67c1bbaf9ae7

How can we reproduce the bug?

No response

What browsers are you seeing the problem on?

Chrome

Contact Details

rich@dxos.org

Code of Conduct

linear[bot] commented 2 weeks ago

TLD-2482 [Bug]: RTE: TypeError: Cannot read properties of undefined (reading 'currentPageId')