Which nuget package do I need for both online and on-prem?

%3CLINGO-SUB%20id%3D%22lingo-sub-1733326%22%20slang%3D%22en-US%22%3EWhich%20nuget%20package%20do%20I%20need%20for%20both%20online%20and%20on-prem%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1733326%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20everyone%2C%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EI've%20been%20reading%20through%20a%20lot%20of%20sharepoint%20docs%20lately%20as%20I%20begin%20to%20upgrade%20an%20existing%20(a%20bit%20dated)%20sharepoint%20CSOM%20solution.%20I%20came%20across%20the%26nbsp%3B%3CA%20title%3D%22SharePointPnPCoreOnline%22%20href%3D%22https%3A%2F%2Fwww.nuget.org%2Fpackages%2FSharePointPnPCoreOnline%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3ESharePointPnPCoreOnline%3C%2FA%3E%26nbsp%3Bpackage%20which%20seems%20to%20have%20all%20the%20APIs%20I'd%20need%20(OAuth%2C%20File%2C%20Attachments).%3C%2FP%3E%0A%3CP%3ENow%20in%20the%20%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fpnp%2FPnP-Sites-Core%2Fblob%2Fmaster%2FCore%2FREADME.md%23compiling-for-sharepoint-2013%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%22%3EReadme%20of%20the%20github%20repo%3C%2FA%3E%2C%20you%20can%20see%20that%20there%20are%20some%20compiler%20directives%20available%20that%20I%20can%20(probably)%20use%20to%20generate%20binaries%20targeting%20Online%20and%20various%20On-Prem%20versions%20from%20the%20same%20code-base.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWe%20do%20want%20to%20provide%20binaries%20of%20our%20solution%20for%20all%204%20targets%2C%20so%20I%20want%20to%20know%20which%20of%20the%20%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fpnp%2FPnP-Sites-Core%2Fblob%2Fmaster%2FCore%2Fnuget.md%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%22%3E4%20nuget%20packages%3C%2FA%3E%20would%20I%20need%20to%20include%20in%20my%20solution%3F%3C%2FP%3E%0A%3CP%3EOr%20do%20I%20need%20to%20make%20a%20conditional%20CSPROJ%20which%20includes%20the%20right%20package%20depending%20on%20the%20chosen%20target%3F%20If%20so%2C%20then%20what%20are%20those%20compiler%20directives%20for%3F%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EEdit%3A%20Added%20link%20to%204%20potential%20nuget%20packages%3C%2FP%3E%3C%2FLINGO-BODY%3E
Microsoft

Hi everyone,

 

I've been reading through a lot of sharepoint docs lately as I begin to upgrade an existing (a bit dated) sharepoint CSOM solution. I came across the SharePointPnPCoreOnline package which seems to have all the APIs I'd need (OAuth, File, Attachments).

Now in the Readme of the github repo, you can see that there are some compiler directives available that I can (probably) use to generate binaries targeting Online and various On-Prem versions from the same code-base.

 

We do want to provide binaries of our solution for all 4 targets, so I want to know which of the 4 nuget packages would I need to include in my solution?

Or do I need to make a conditional CSPROJ which includes the right package depending on the chosen target? If so, then what are those compiler directives for?

 

Edit: Added link to 4 potential nuget packages

0 Replies