-2

So today I was updating one of our SPFX extensions to use the latest spfx framework (1.16) with node (16.13) and after finishing my updates I got the following inside my code: enter image description here I am not exactly sure why these are not coming in, I suspect the newest version of spfx moves these classes out of sp-application-base, but why? and where is the documentation for it? Because there is this link that is only 6 months old and explains to use this code for the top and bottom headers.

I was expecting this code to remain in sp-application-base, but it appears it isn't in that package.

2 Answers2

0

It is still there. What version of @microsoft/sp-application-base is in your project? Should be 1.16.1 I believe. I will say that I am new to all of this as well, but I am using the latest framework and VS is not flagging any issues with these.

langsky
  • 11
  • 1
  • I newly installed it today and it installed 1.15.2. I used 1.16.1 yesterday, I installed 1.12.1 yesterday and that seemed to solve the issue. But I wanted to build with the latest install. – Todd Coulson Jan 26 '23 at 14:15
0

How did you perform the upgrade? I highly recommend using the Microsoft 365 CLI to upgrade projects, as the developers of that app do thier best to cover every part of the project that needs to change. Learn more at https://pnp.github.io/cli-microsoft365/cmd/spfx/project/project-upgrade/

Here are the commands to run from the root of your project

npm install -g @pnp/cli-microsoft365
m365 spfx project upgrade --output text

This will give a list of npm commands and code update instructions to follow. See the above documentation for other options for output and use whatever works best for you.

E_net4
  • 27,810
  • 13
  • 101
  • 139
Don Kirkham
  • 105
  • 9