We'll add the MainShell file directly to the root of the .NET Standard Library. There is no template for a shell available, so we need to add a regular content page file and make some minor changes to it. No worries—it's quickly done, as detailed here:
- In the News project, right-click the project node, select Add, and then click New Item... .
- Under the Visual C# Items node on the left, select Xamarin.Forms.
- Select Content Page and name it MainShell.
- Click Add to create the page.
Excellent! Now, we need to modify the XAML and change the root node to Shell and remove some unnecessary tags.
- In the News project, open the MainShell.xaml file.
- Replace the root node and remove the content of the root node so that the file looks like the code in the following snippet:
<?xml version="1.0" encoding="UTF-8"?>
<Shell xmlns="http://xamarin.com/schemas...