Skip to content

Instantly share code, notes, and snippets.

@JudahGabriel
Last active July 1, 2016 20:59
Show Gist options
  • Save JudahGabriel/3f099ad88a391dc06a8268d2331d8e06 to your computer and use it in GitHub Desktop.
Save JudahGabriel/3f099ad88a391dc06a8268d2331d8e06 to your computer and use it in GitHub Desktop.
// Query for the honey glazed salmon recipe
// and transform it into a RecipeViewModel.
var recipeViewModel = ravenSession.Query<Recipe>()
.TransformWith<RecipeViewModelTransformer, RecipeViewModel>()
.Where(r => r.Name == "Sweet honey glazed salmon")
.First();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment