Paolo ponzano - 87 - Jun 12, 2014

Hello, I was wondering if it’s possible to share the DTO /Requests files between 2 projects (Web and WPF one) using a portable class project in vs2013 but when I try to reference the SS assemblies via nuget I got an error saying there’s no compatible nugetpackage for that kind of project… is it possible in some way?Thanks

Web and WPF both allow full .NET so you don’t need to create a PCL project.

If you want to create a PCL project of your DTO’s you will need to create a separate PCL .NET project which you can then use to link the source files from your existing Service Models which will then allow you to reference ServiceStack’s PCL packages from, i.e. ServiceStack.Interfaces.Pcl. This is mentioned here: https://github.com/ServiceStack/Hello#sharing-server-dtos-with-clients

The repo also contains an example of this approach in the ServiceModel and ServiceModel.Pcl projects: 
https://github.com/ServiceStack/Hello/tree/master/src