Closed parched closed 6 days ago
I have a fix for this but I'm running into trouble with the unit tests working with the treeshaking added to the tsx files.
@millerds do you mind sharing your fix even if the unit tests aren't working?
I created a draft PR of what the changes consist of at https://github.com/OfficeDev/Office-Addin-TaskPane-React/pull/97. The end to end tests pass, but the unit tests fail because of the more specific import statements. I didn't have any luck figuring out a change that would keep the tests, and haven't been able to spend much time on it recently.
Even more so I would expect to not see:
Please note, versions of this package with version numbers x.y.z and below have been deprecated as of 31-March-2022.
in particular not for MSFT office related packages.
When are you seeing that message?
that various packages are not up-to-date (part of MSFT core products) in particular:
npm WARN deprecated @types/webpack-dev-server@4.7.2: This is a stub types definition. webpack-dev-server provides its own type definitions, so you do not need this installed.
npm WARN deprecated @types/react-hot-loader@4.1.1: This is a stub types definition. react-hot-loader provides its own type definitions, so you do not need this installed.
npm WARN deprecated @types/keyv@4.2.0: This is a stub types definition. keyv provides its own type definitions, so you do not need this installed.
npm WARN deprecated @types/jwt-decode@3.1.0: This is a stub types definition. jwt-decode provides its own type definitions, so you do not need this installed.
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated @azure/arm-subscriptions@3.1.2: Please note, versions of this package with version numbers 3.1.2 and below have been deprecated as of 31-March-2022. We strongly encourage you to upgrade to version 4.0.0 or above to continue receiving updates. Refer to our deprecation policy: https://azure.github.io/azure-sdk/policies_support.html for more details.
npm WARN deprecated @azure/arm-resources@4.2.2: Please note, versions of this package with version numbers 4.2.2 and below have been deprecated as of 31-March-2022. We strongly encourage you to upgrade to version 5.0.0 or above to continue receiving updates. Refer to our deprecation policy: https://azure.github.io/azure-sdk/policies_support.html for more details.
npm WARN deprecated @azure/arm-storage@15.3.0: Please note, versions of this package with version numbers 16.1.2 and below have been deprecated as of 31-March-2022. We strongly encourage you to upgrade to version 17.0.0 or above to continue receiving updates. Refer to our deprecation policy: https://azure.github.io/azure-sdk/policies_support.html for more details.
npm WARN deprecated @azure/arm-appservice@7.0.0: Please note, versions of this package with version numbers 9.0.0 and below have been deprecated as of 31-March-2022. We strongly encourage you to upgrade to version 10.0.0 or above to continue receiving updates. Refer to our deprecation policy: https://azure.github.io/azure-sdk/policies_support.html for more details.
npm WARN deprecated @azure/arm-apimanagement@6.0.0: Please note, versions of this package with version numbers 7.2.0 and below have been deprecated as of 31-March-2022. We strongly encourage you to upgrade to version 8.0.0 or above to continue receiving updates. Refer to our deprecation policy: https://azure.github.io/azure-sdk/policies_support.html for more details.
npm WARN deprecated @azure/arm-sql@7.1.2: Please note, versions of this package with version numbers 8.0.0 and below have been deprecated as of 31-March-2022. We strongly encourage you to upgrade to version 9.0.0 or above to continue receiving updates. Refer to our deprecation policy: https://azure.github.io/azure-sdk/policies_support.html for more details.
I am talking in particular also about the Azure related libraries like:
npm WARN deprecated @azure/arm-resources@4.2.2: Please note, versions of this package with version numbers 4.2.2 and below have been deprecated as of 31-March-2022. We strongly encourage you to upgrade to version 5.0.0 or above to continue receiving updates. Refer to our deprecation policy: https://azure.github.io/azure-sdk/policies_support.html for more details.
I think part of the problem is that the vendor code is being included in both the vendor bundle and the taskpane bundle.
The problem was that vendor was getting built, but taskpane was not using it as a reference, but including everything directly. I've checked in a change in master branch to fix this. It will be part of the template the next time we push officially to yo-office.
Expected behavior
When running
npm run build
with nothing added to the basic template I expected to get no warnings about the bundle sizesCurrent behavior
I get these warnings
Steps to Reproduce
Please provide detailed steps for reproducing the issue.
npm run build
Context
Failure Logs