Skip to content

WP Build: Page crashes with "Element type is invalid" error. #75440

@dhasilva

Description

@dhasilva

Description

After this PR wp-build pages are breaking with the following message:

Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.

Check the render method of `RootSinglePage`.

Step-by-step reproduction instructions

  1. Go to a page that uses wp-build.
  2. Check the error.

A simple plugin where this can be tested: https://github.com/dhasilva/minimal-wp-build-test (ignore the "No Gutenberg" thing, it was meant to debug another issue, but serves to test this as well)

Screenshots, screen recording, code snippet

Image Image

Environment info

  • Gutenberg trunk

Please confirm that you have searched existing issues in the repo.

  • Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

  • Yes

Please confirm which theme type you used for testing.

  • Block
  • Classic
  • Hybrid (e.g. classic with theme.json)
  • Not sure

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions