Skip to content

Comments

Upgrade @wp-playground/client to v3 for PHP 8.5 support#24

Merged
srtfisher merged 35 commits intomainfrom
copilot/upgrade-wp-playground-client
Feb 12, 2026
Merged

Upgrade @wp-playground/client to v3 for PHP 8.5 support#24
srtfisher merged 35 commits intomainfrom
copilot/upgrade-wp-playground-client

Conversation

Copy link
Contributor

Copilot AI commented Feb 11, 2026

Upgrades WordPress Playground client to v3.0.46, adding PHP 8.5 support.

Changes

  • Package upgrade: @wp-playground/client v1.0.28 → v3.0.46
  • Peer dependencies: Added @wp-playground/blueprints, @php-wasm/universal, @php-wasm/util, @wp-playground/remote (required by v3)
  • Breaking change fix: StepDefinition import moved from @wp-playground/client to @wp-playground/blueprints
  • Default PHP version: Updated from 8.3 to 8.4
// resources/js/components/playground.tsx
- import { startPlaygroundWeb, StepDefinition } from '@wp-playground/client';
+ import { StepDefinition } from '@wp-playground/blueprints';
+ import { startPlaygroundWeb } from '@wp-playground/client';
// resources/js/lib/constants.ts
- export const DEFAULT_PHP_VERSION = '8.3';
+ export const DEFAULT_PHP_VERSION = '8.4';

Supported PHP versions: 8.5, 8.4, 8.3, 8.2, 8.1, 8.0, 7.4

Original prompt

This section details on the original issue you should resolve

<issue_title>Upgrade @wp-playground/client package to v3</issue_title>
<issue_description>- Upgrade to the latest @wp-playground/client package.

  • Ensure that we can use PHP 8.5.</issue_description>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

srtfisher and others added 28 commits February 11, 2026 14:35
- Parse wordpress-stubs to extract 3900+ WordPress function signatures
- Create autocomplete provider with function names, signatures, and descriptions
- Register completion provider in Monaco editor beforeMount hook
- Enable quickSuggestions for better autocomplete UX
- Enable resolveJsonModule in TypeScript config

Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
…ing comment

Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
- Create npm script to regenerate WordPress functions data
- Add 'since' version info to function metadata
- Include clickable links to WordPress developer docs in autocomplete
- Show 'since WordPress X.X' in function detail
- Add scripts/README.md with maintenance instructions

Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
The issue was that ${1:$post_id} format caused Monaco to treat $post_id as a variable reference, showing empty placeholders. Changed to ${1:post_id} format which displays parameter names correctly.

- Updated generation script to omit $ from placeholder text
- Regenerated wordpress-functions.json with fixed format
- Build passes successfully

Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Test ensures that after selecting an autocomplete suggestion, parameter names are visible (not empty like "get_post_meta(, , )").

Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Document that parameter names don't include $ in placeholders and explain how Monaco snippet syntax works.

Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
- Add explicit wait for specific suggestions before selecting
- Add small delays after autocomplete insertions
- Use more specific selectors to avoid race conditions
- Ensure tests are more robust for async operations

Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
…h mobile stacked view

Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
…eyinteractive/wp-repl into copilot/improve-mobile-ux-for-panels
…ments

Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Base automatically changed from copilot/improve-mobile-ux-for-panels to main February 11, 2026 21:57
Copilot AI and others added 2 commits February 11, 2026 22:00
Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Copilot AI changed the title [WIP] Upgrade @wp-playground/client package to v3 Upgrade @wp-playground/client to v3 for PHP 8.5 support Feb 11, 2026
Copilot AI requested a review from srtfisher February 11, 2026 22:04
@srtfisher
Copy link
Member

@copilot default should be 8.4 but we must also have 8.5 supported.

@srtfisher srtfisher marked this pull request as ready for review February 11, 2026 22:07
Co-authored-by: srtfisher <346399+srtfisher@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Feb 11, 2026

@copilot default should be 8.4 but we must also have 8.5 supported.

Updated to use 8.4 as the default while keeping 8.5 supported. See commit e0ecf15.

@srtfisher srtfisher merged commit 85d5455 into main Feb 12, 2026
2 of 3 checks passed
@srtfisher srtfisher deleted the copilot/upgrade-wp-playground-client branch February 12, 2026 14:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Upgrade @wp-playground/client package to v3

2 participants