Skip to content

Conversation

adamziel
Copy link
Collaborator

@adamziel adamziel commented Apr 19, 2024

Fixes the stuck Playground loading process on
https://playground.wordpress.net/builder/builder.html

Technically, we trash the existing iframe and start a new one instead of trying to bind multiple Playground clients to the same one. They very likely competed for events and missing even a single one meant not finishing the Playground loading sequence.

This also fixes the following issues with the builder:

  • Cmd+s saving the Blueprint to the disk instead of running it
  • Too many double quotes inserted when completing a step name

Furthermore, it adds an "Edit the Blueprint" link to the hamburger menu.

Closes #863

Follow-up work

Scrap the entire Builder codebase and rebuild it with CodeMirror and generic autocompletion (Ace doesn't work well for mobile, and the current autocompletion is bound to an exact JSON schema shape).

Testing plan

  1. Go to http://127.0.0.1:5400/website-server/builder/builder.html
  2. Run a few Blueprints
  3. Reload them 40 times
  4. Confirm Playground loaded every single time
Fixes the stuck Playground loading process on https://playground.wordpress.net/builder/builder.html Technically, we trash the existing iframe and start a new one instead of trying to bind multiple Playground clients to the same one. They very likely competed for events and missing even a single one meant not finishing the Playground loading sequence. This also fixes the following issues with the builder: * Cmd+s saving the Blueprint to the disk instead of running it * Too many double quotes inserted when completing a step name ## Follow-up work Scrap the entire Builder codebase and rebuild it with CodeMirror and generic autocompletion (Ace doesn't work well for mobile, and the current autocompletion is bound to an exact JSON schema shape). ## Testing plan 1. Go to http://127.0.0.1:5400/website-server/builder/builder.html 1. Run a few Blueprints 1. Reload them 40 times 1. Confirm Playground loaded every single time
@adamziel adamziel added [Type] Bug An existing feature does not function as intended [Package][@wp-playground] Blueprints labels Apr 19, 2024
@adamziel adamziel merged commit 0a0f03f into trunk Apr 19, 2024
@adamziel adamziel deleted the fix-builder branch April 19, 2024 15:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Package][@wp-playground] Blueprints [Type] Bug An existing feature does not function as intended

1 participant