[Map] Allows Bridges JavaScript assets to be installed with npm
when using file:vendor/symfony/ux-*-map/assets
#2983
+20
−30
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.
Alternative to #2982.
Moving the
"@symfony/ux-map": "workspace:*"
requirements outside the package.json allows the Bridges JavaScript assets to be installed withnpm
when@symfony/ux-leaflet-map
(or@symfony/ux-google-map
) is using constraint versionfile:vendor/symfony/ux-leaflet-map/assets
(orfile:vendor/symfony/ux-google-map/assets
) in the user application.This is possible to this super feature from pnpm: packageExtensions, which allows to override some part of package definitions in file
pnpm-workspace.yaml
:@symfony/ux-map
is a dependency of@symfony/ux-leaflet-map
and@symfony/ux-google-map
🎉workspace:*
anymore in anypackage.json
🎉It is not possible to defines
packageExtensions.devDependencies
, so I usedpackageExtensions.dependencies
instead but that's fine.@symfony/ux-map
is not referenced in anypackage.json
when runningpnpm pack
insrc/Bridge/*/assets
.