tomjn / Frontenberg

A WP theme providing a read only demo of the post block editor on the frontend, provided as is, no support.
https://frontenberg.tomjn.com/
135 stars 30 forks source link

Uncaught TypeError: Cannot read property 'switchEditorMode' of null #14

Closed dovy closed 4 years ago

dovy commented 4 years ago

I think I've found my issue. I am getting the following error:

actionHelper.js:7 Uncaught TypeError: Cannot read property 'switchEditorMode' of null
    at Module../src/stores/actionHelper.js (actionHelper.js:7)
    at __webpack_require__ (bootstrap:79)
    at Module../src/plugins/sidebar-share/sidebar.js (index.js:15)
    at __webpack_require__ (bootstrap:79)
    at Module../src/plugins/sidebar-share/index.js (index.js:1)
    at __webpack_require__ (bootstrap:79)
    at Module../src/index.js (index.js:1)
    at __webpack_require__ (bootstrap:79)
    at checkDeferredModules (bootstrap:45)
    at bootstrap:152

The code in question is no more than const {switchEditorMode} = dispatch('core/edit-post');.

I think something isn't loading properly. Any ideas? It works if I go the admin path.

tomjn commented 4 years ago

I have no idea what's going on there