feat(external-router): Support different Magento driver versions#4424
feat(external-router): Support different Magento driver versions#4424joannalauu wants to merge 26 commits intodevelopfrom
Conversation
b3f4d21 to
e21fdf8
Compare
9681673 to
6697354
Compare
…versions are not in bundle
|
Tests in commit 47d7b9a uses the updated commerce test workflow, validating expected behavior |
|
Test failures in commit e1588cc verifies that when using a base provider to control driver version, tree shaking doesn't work and unused driver versions are included in the bundle |
|
After a lengthy discussion with @joannalauu we came to a new idea. Essentially there will be a new {
"projects": {
"provider-test": {
"drivers": {
"magento": "1.9.4"
}
}
}
}We also will have tests guaranteeing that our bundles sizes remain small. Below follows the list of notes that we generated during our discussion. =========
daff.json - {
"projects": {
"provider-test": {
"drivers": {
"magento": "1.9.4"
}
}
}
}
`daff.json` for nx projects w/ project.json
```json
{
"drivers": {
"magento": "2.4.7",
"shopify": "2026-01",
"hubspot": "kjnasdkjhasbdkjahsbdlkjhasbd"
}
} |
griest024
left a comment
There was a problem hiding this comment.
I don't like this solution. You've confirmed that the unused driver versions don't get tree shaken out?
|
@griest024 have you reviewed my comment above? |
Yes, test failures in commit e1588cc verifies that when using a base provider to control driver version, tree shaking doesn't work and unused driver versions are included in the bundle |
yes, see the discord thread. I think this requires further discussion |
PR Checklist
PR Type
Current behavior
Fixes: #3137
New behavior
@daffodil/external-router/driver/magento/instead of@daffodil/external-router/driver/magento/2.4.3./driver/magentoexport condition to resolve to the specific driver version in the dist package.jsonlibs/external-router/scripts/patch-magento-exports.mjsangular.jsonandtsconfig.jsonguides/drivers/magento.mdenv.DEFAULT_MAGENTO_VERSIONwill need to be updated@daffodil/external-router/driver/magento/2.4.3because patch only applies to imports fromnode_modules, notdist/Breaking change?
Additional context