Skip to Content
.NET Standard 2.0 Cookbook
book

.NET Standard 2.0 Cookbook

by Fiqri Ismail
May 2018
Intermediate to advanced content levelIntermediate to advanced
394 pages
9h 51m
English
Packt Publishing
Content preview from .NET Standard 2.0 Cookbook

How it works...

In steps 1 to 12, we added a blank solution and then we added a .NET Standard 2.0 class library to the solution. In these steps, we assigned proper names to the solution and the project. In steps 13 and 14, we renamed the default class template to something more meaningful. You can also delete this class and create a new one.

In step 15, we added two namespaces to the code. In step 16, we created a class-level variable and created an instance of the HttpClient class. In step 17, we created an asynchronous public method that reads the given site content as a string and returns the read content.

Finally, we performed a quick build to check the syntax.

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

C# 7 and .NET Core 2.0 High Performance

C# 7 and .NET Core 2.0 High Performance

Ovais Mehboob Ahmed Khan
.NET Core 2.0 By Example

.NET Core 2.0 By Example

Neha Shrivastava, Rishabh Verma

Publisher Resources

ISBN: 9781788834667Supplemental Content