pnp / pnpjs

Fluent JavaScript API for SharePoint and Microsoft Graph REST APIs
https://pnp.github.io/pnpjs/
Other
740 stars 300 forks source link

version 4 - @pnp/sp/favorites doesn't exists #3044

Closed JamesDerrickHH closed 1 month ago

JamesDerrickHH commented 1 month ago

What version of PnPjs library you are using

4.x

Minor Version Number

4.0.1

Target environment

All

Additional environment details

I'm building a sharepoint webpart (1.19) using react (17)

Question/Request

I'm trying to pull back all items for a site that have been favourited However, webpack gives me a compile error saying the module doesn't exist I have imported it, as per the documents, import "@pnp/sp/favorites"; Looking at the code it seems to exist in version 3 but not version 4, is this intentional? Is there anything I can do to work around this?

juliemturner commented 1 month ago

@JamesDerrickHH, yes it was intentional as noted in our changelog because those endpoints are better supported by graph calls. I think what you're looking for is followed sites.

JamesDerrickHH commented 1 month ago

Thanks, I'm specifically looking to get followed items and folders, but knowing that graph is the way to go is more than enough to start investigating

github-actions[bot] commented 1 month ago

This issue is locked for inactivity or age. If you have a related issue please open a new issue and reference this one. Closed issues are not tracked.