Use Node.js Polyfills in the Blueprints package#882
Merged
Conversation
Makes Playground Blueprints compatible with Node.js v18 by using a set of polyfills shiped in #875. Test plan: Confirm the CI checks passed
adamziel
pushed a commit
to WordPress/playground-tools
that referenced
this pull request
Apr 3, 2024
Remove message that asks for Node v20 when`--blueprint` param is present. ## Why? <!-- Why is this PR necessary? What problem is it solving? Reference any existing previous issue(s) or PR(s), but please add a short summary here, too --> Since the polyfills were implemented on WordPress/wordpress-playground#882 , blueprints can be executed on Node v18 ## Testing Instructions <!-- Please include step by step instructions on how to test this PR. --> <!-- 1. Check out the branch. --> <!-- 2. Run a command. --> <!-- 3. etc. --> * Create a new blueprint file `b.json` with a valid blueprint like: ``` { "landingPage": "/wp-admin/", "features": { "networking": true }, "steps": [ { "step": "login", "username": "admin", "password": "password" } ] } ``` * Run `nvm use && npm install && npx nx run wp-now:build` # nvm use will set the node version 18.18.2 * Run `node dist/packages/wp-now/with-node-version.js start --blueprint=b.json` * Observe the blueprint runs as expected and there is no the following error `This script is requires node version v20.0.0 or above when --blueprint=<file> is used; found v18.18.2`
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Makes Playground Blueprints compatible with Node.js v18 by using a set of polyfills shiped in #875.
Test plan
Confirm the CI checks passed