Search code examples
windows-10windows-10-mobile

How to use Shared Projects in Universal Windows Platform (Windows 10)?


With Windows 8.1 developers could create shared projects that were common to a Windows Phone project and Windows 8.1 project and have non-common code in different folders. Upon build for each platform the corresponding folder is used. I am migrating an app to UWP and I can't find a way to use this functionality. I realize I can continue to use Windows 8.1 project template but I want to use other UAP features like x:Bind. I am not a fan of the whole responsive design thing and what is more I already have custom UI for tablet and phone so I would really like to use shared projects if possible. Any hints?


Solution

  • Device Family specific folders should fit your needs.

    Here is a blog post with code samples: http://igrali.com/2015/08/02/three-ways-to-set-specific-devicefamily-xaml-views-in-uwp/