Simplify.Web.Json 2.3.1

dotnet add package Simplify.Web.Json --version 2.3.1
NuGet\Install-Package Simplify.Web.Json -Version 2.3.1
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Simplify.Web.Json" Version="2.3.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Simplify.Web.Json --version 2.3.1
#r "nuget: Simplify.Web.Json, 2.3.1"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Simplify.Web.Json as a Cake Addin
#addin nuget:?package=Simplify.Web.Json&version=2.3.1

// Install Simplify.Web.Json as a Cake Tool
#tool nuget:?package=Simplify.Web.Json&version=2.3.1

Simplify.Web.Json

Nuget Version Nuget Download Build PackageLibraries.io dependency status for latest release CodeFactor Grade Platform PRs Welcome

Simplify.Web.Json is a package which provides JSON serialization/deserialization for Simplify.Web web-framework controllers.

Quick Start

Sending JSON to client

If the controller returns Json response class object, then the Framework execution will be stopped, object will be parsed to JSON string and sent to client

public class MyController : Controller
{
    public override ControllerResponse Invoke()
    {
        ...
        return new Json(myObj);
    }
}

Getting JSON from client

Registering binder
public void Configuration(IApplicationBuilder app)
{
    ...
    HttpModelHandler.RegisterModelBinder<JsonModelBinder>();

    app.UseSimplifyWeb();
}

public void ConfigureServices(IServiceCollection services)
{
    ...
    DIContainer.Current.RegisterJsonModelBinder();
    ...
}
Accessing model
Asynchronous
public class MyController : ControllerAsync<MyModel>
{
    public override async Task<ControllerResponse> Invoke()
    {
        await ReadModelAsync();

        Model.
    }
}
Synchronous

JSON string will be deserialized to the controller model on first model access

public class MyController : Controller<MyModel>
{
    public override ControllerResponse Invoke()
    {
        Model.
    }
}
Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 is compatible. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 is compatible.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2.3.1 218 12/20/2023
2.3.0 210 8/20/2023
2.2.5 342 3/11/2023
2.2.4 367 11/30/2022
2.2.3 597 5/18/2022
2.2.2 5,528 11/24/2021
2.2.1 558 4/26/2021
2.2.0 479 3/23/2021
2.1.3 469 2/28/2021
2.1.2 597 10/26/2020
2.1.1 668 4/29/2020
2.1.0 621 1/30/2020
2.0.1 585 1/27/2020
2.0.0 642 12/22/2019
2.0.0-pre02 409 12/17/2019
2.0.0-pre01 305 8/24/2019
1.4.0 688 10/21/2019
1.3.0 604 10/20/2019
1.2.4 635 9/28/2019
1.2.3 613 9/3/2019
1.2.2 622 8/25/2019
1.2.1 599 8/22/2019
1.2.0 826 1/3/2019
1.1.3 1,074 5/9/2018
1.1.2 1,012 8/23/2017
1.1.1 1,339 11/4/2016
1.1.0 1,016 10/7/2016
1.0.0 1,014 8/26/2016
0.9.0 1,040 8/23/2016