The build will fail: Error - [tsc] src/webparts/helloWorld/HelloWorldWebPart.ts(45,25): error TS2345: Argument of type '"blob"' is not assignable to parameter of type 'ResponseType'.
Expected behavior: [What you expected to happen]
The string "blob" to be accepted as an argument for responseType method on the GraphRequest.
Actual behavior: [What actually happened]
Cannot build because of error.
Additional Context
"@microsoft/sp-http": "^1.18.2" was installed
Usage Information
Request ID - Value of the requestId field if you are receiving a Graph API error response
SDK Version - [SDK version you are using]
[x] Node (Check, if using Node version of SDK)
Node Version - 18
[ ] Browser (Check, if using Browser version of SDK)
Browser Name - [The name of Browser that you are using for SDK]
Version - [The version of the browser you are using]
Bug Report
Hello, I've created a new web part in my SPFX project and my SPFX package version was upgraded from 1.17 to 1.18 automatically by the creation wizard.
This seem to have brought a breaking change with existing Microsoft Graph code used in the project.
Prerequisites
For more information, see the
CONTRIBUTING
guide.Description
Here is my code:
And the IDE error:
Argument of type '"blob"' is not assignable to parameter of type 'ResponseType'.ts(2345)
Console Errors: [Is there any console error]
Screenshots: [If applicable, add screenshots to help explain your problem]
Steps to Reproduce
yo @microsoft/sharepoint
npm i @microsoft/sp-http
src/webparts/helloWorld/HelloWorldWebPart.ts
onInit
method to look like this:gulp serve
commandError - [tsc] src/webparts/helloWorld/HelloWorldWebPart.ts(45,25): error TS2345: Argument of type '"blob"' is not assignable to parameter of type 'ResponseType'.
Expected behavior: [What you expected to happen] The string "blob" to be accepted as an argument for responseType method on the GraphRequest.
Actual behavior: [What actually happened] Cannot build because of error.
Additional Context
"@microsoft/sp-http": "^1.18.2" was installed
Usage Information
Request ID - Value of the
requestId
field if you are receiving a Graph API error responseSDK Version - [SDK version you are using]