[PHP.wasm for Node] Fix php.js import path in the published npm package #1958
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.
@sejas has brought to our attention that the imports of the wasm assets are using incorrect paths, since 3bebb24.
The source says something like:
Which currently results in the built file saying:
However, since the tree of the published package is as follows, the path in the built file is missing a leading
/php
.This PR fixes the issue by making it so that the imports have a leading
/php
, which results in the import being:Testing instructions
Build the package:
Then make sure that the paths in
dist/packages/php-wasm/web/index.js
(around line 95) are correct, i.e../php/jspi/php_8_3.js
.