You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Support Node.js args to built-script executor (#92)
## Motivation for the change, related issues
When running Playground CLI and php-wasm CLI with the built-script
executor, I've wanted to add extra Node.js flags like
`--experimental-wasm-jspi`.
Prior to this PR, the only way was to hack the executor.ts file, but
these changes show up in `git status` and are easy to misplace and lose
when switching between branches and pushing and popping from the stash.
## Implementation details
This PR adds a `nodeArg` option to our custom `built-script` executor.
It is an array and can be specified multiple times to add multiple args.
## Testing Instructions (or ideally a Blueprint)
The built-script executor is only used by Playground CLI and php-wasm
CLI. Let's test both.
Run the following command:
```
npx nx start php-wasm-cli --nodeArg='--cpu-prof' --nodeArg='--trace-promises' -r 'phpinfo();'
```
- Confirm you see promise tracing in the output
- Confirm the command created a file ending in `.cpuprofile`
Run `npx nx start playground-cli server` to confirm it is still working.
0 commit comments