Some common extensions for Prism Projects
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
src
.gitignore
Directory.build.props
LICENSE
NuGet.config
Prism.Extensions.sln
ReadMe.md

ReadMe.md

Prism Extensions

This library provides common extensions for Prism projects using either Prism Core or Prism Forms.

Build status

Package Version
Prism.Core.Extensions 21
Prism.Forms.Extensions 22

Logging

Logging should be easy. With the Logging Extensions you can pass any object into the logger without having to explicitly call ToString(). By default all Exceptions passed in will be logged as Exceptions, while all other objects will be logged as Debug outputs. You can optionally override the logging Category for any object being logged.

Prism Forms Navigation

Prism Forms users can make navigation just a little easier with the Navigation extensions.

public class TodoItem { }

// pass the item directly with the parameter key todoItem
private async void OnTodoItemTapped(TodoItem todoItem) =>
    await _navigationService.NavigateAsync("TodoItemDetail", todoItem);

// pass the item directly with a specified key
private async void OnTodoItemTapped(TodoItem todoItem) =>
    await _navigationService.NavigateAsync("TodoItemDetail", "tappedItem", todoItem);


private async void NavigateToTodoItemList() =>
    await _navigationService.NavigateAsync("TodoItemList", "todoItems", todoItem1, todoItem2, todoItem3;)

private async void NavigateToTodoItemList()
{
    var items = new List<TodoItem>()
    {
        new TodoItem(),
        new TodoItem()
    }
    // Adds the Todo Item list with the key 'todoItem'
    await _navigationService.NavigateAsync("TodoItemList", items )
}