Fix Gutenberg Mobile dependencies resolution#3659
Merged
Merged
Conversation
Gutenberg mobile dependencies were resolved using the Jetpack path, so now we check first if the module exists in the Jetpack submodule before solving it with that path.
This dependency is already defined in Jetpack submodule and it's only used there.
hypest
reviewed
Jun 24, 2021
|
Wanna run full suite of Android and iOS UI tests? Click here and 'Approve' CI job! |
hypest
approved these changes
Jun 24, 2021
Contributor
hypest
left a comment
There was a problem hiding this comment.
LGTM! Let's auto-merge when CI green.
✅ CI jobs should be green on this PR. It was green on 0837df7 already.
✅ Demo app should run normally
✅ As a double-check, verify that the Contact info block works as expected because it's the one that imports the email-validator package. ➡️ I verified that when the email is well-formed, the html output includes a mailto: link, while if not well-formed it's just plain text, just like expected by the code.
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.
I added a new dependency to the
package.jsonfile of Gutenberg Mobile in this PR and I noticed that Metro was throwing an error due to not being able to resolve it.After checking the extra node modules resolver, I realized that the dependencies that are not resolved via the Gutenberg submodule were considered to be located in the Jetpack submodule, including the ones defined in Gutenberg Mobile. To address this, I basically added a condition that checks if the path exists before considering it a dependency within Jetpack.
Additionally, I removed the dependency
email-validatorfrom Gutenberg Mobile because it's already in the Jetpack submodule, in fact, it's not even referenced in the Gutenberg Mobile code.As a side note, these are the dependencies resolved from the Jetpack submodule:
@automattic/color-studioemail-validatorTo test:
email-validatorpackage.PR submission checklist: