Introduction

Before we start delving into the details of Glass.Mapper.Sc lets see how easy it is to start mapping data from Sitecore. It is time to create the Hello World example.

Working with the framework is very simple, the easiest way to start is just to create a standard C# class. This class uses standard .NET types and a single custom Glass.Mapper.Sc type called Image. The Image type is used to map Sitecore Image fields.

After creating the class you can use one of the Glass.Mapper.Sc services to retrieve an item from the Sitecore database and map it directly to the model:

In the next exercise you will create a rendering that replaces the existing welcome banner with a banner that uses content from Sitecore:

In this exercise you will see how you can start mapping data with plain old C# objects and a few lines of code.

Complete and Continue