Skip to content

Can't load forms in a headless single page application in different domain / Improve error handling among other things  #9

Description

@k1sul1

Describe the bug
If this component is used without a window.wplfData in place, it will fail with a cryptic "Unexpected token at 0".

If the request to the form is 403'd for some reason (nonce!!) it will display the loading state forever, in my case:

image

To Reproduce
Steps to reproduce the behavior:

  1. Install the component from npm
  2. Import it and use it in code without supplying wplfData
  3. See error

In other words, headless single page applications are in quite a spot at the moment.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions