spfx project upgrade¶
Upgrades SharePoint Framework project to the specified version
spfx project upgrade [options]
||output usage information|
||The version of SharePoint Framework to which upgrade the project|
||Runs command with verbose logging|
||Runs command with debug logging|
Run this command in the folder where the project that you want to upgrade is located. This command doesn't change your project files.
spfx project upgrade command helps you upgrade your SharePoint Framework project to the specified version. If no version is specified, the command will upgrade to the latest version of the SharePoint Framework it supports (v1.7.1).
This command doesn't change your project files. Instead, it gives you a report with all steps necessary to upgrade your project to the specified version of the SharePoint Framework. Changing project files is error-prone, especially when it comes to updating your solution's code. This is why at this moment, this command produces a report that you can use yourself to perform the necessary updates and verify that everything is working as expected.
Using this command you can upgrade SharePoint Framework projects built using versions: 1.0.0, 1.0.1, 1.0.2, 1.1.0, 1.1.1, 1.1.3, 1.2.0, 1.3.0, 1.3.1, 1.3.2, 1.3.4, 1.4.0, 1.4.1, 1.5.0, 1.5.1, 1.6.0 and 1.7.0.
Get instructions to upgrade the current SharePoint Framework project to SharePoint Framework version 1.5.0 and save the findings in a Markdown file
spfx project upgrade --toVersion 1.5.0 --output md > upgrade-report.md
Get instructions to Upgrade the current SharePoint Framework project to SharePoint Framework version 1.5.0 and show the summary of the findings in the shell
spfx project upgrade --toVersion 1.5.0
Get instructions to upgrade the current SharePoint Framework project to the latest SharePoint Framework version supported by the Office 365 CLI
spfx project upgrade