Skip to content

Map block renders in page editor but not template editor #500

@iandunn

Description

@iandunn

#498 rendered the map blocks in the editor, and that worked on the SotW page in my tests. Today I noticed that it's now rendered as a This block has encountered an error and cannot be previewed placeholder.

This error is in the console:

Uncaught ReferenceError: wporgGoogleMap is not defined
    Edit index.js:21

It seems like the PHP render() function gets called in the page editor, but not the site editor. I tried switching to a <ServerSideRender>, but that didn't work.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    🛑 Pending discussion

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions