You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Now that I upgraded to SPFx 1.15.0 (with newer TS and strict ESlint) I get TS Error:
Argument of type 'WebPartContext' is not assignable to parameter of type 'ISPFXContext'.
The types of 'msGraphClientFactory.getClient' are incompatible between these types.
Type '(version: "3") => Promise' is not assignable to type '() => Promise'.ts(2345)
Steps to Reproduce
Just use the code from the documentation the error will show.
Is PnP.JS not ready for 1.15.1? any workaround that will work?
Thank you for your help!
The text was updated successfully, but these errors were encountered:
If you are not using Graph then this workaround should get past the compiler errors: spfi().using(SPFx((this.context as unknown) as ISPFXContext))
If you are using Graph then it may be more complex. I don't know the inner workings of PnPjs well enough to be sure. A quick code search seems to suggest it doesn't get used at all but I am probably missing something.
Category
Version
Please specify what version of the library you are using: [ 3.4.1 ]
Please specify what version(s) of SharePoint you are targeting: [ SPO SPFx 1.15.0 ]
If you are not using the latest release, please update and see if the issue is resolved before submitting an issue.
Expected / Desired Behavior / Question
No issue with code from the example
Observed Behavior
Now that I upgraded to SPFx 1.15.0 (with newer TS and strict ESlint) I get TS Error:
Steps to Reproduce
Just use the code from the documentation the error will show.
Is PnP.JS not ready for 1.15.1? any workaround that will work?
Thank you for your help!
The text was updated successfully, but these errors were encountered: