dotnet / dotnet/AspNetCore.Docs
Add sample code for JsonPatchDocument<TModel>
- Dominant language
- C#
- Stars
- 13.1k
- Forks
- 24.6k
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 97
Description
The documentation is silent about the fact that you can build JSON Patch document (and its paths) with strongly typed lambda expressions using: https://learn.microsoft.com/en-us/dotnet/api/microsoft.aspnetcore.jsonpatch.jsonpatchdocument-1?view=aspnetcore-7.0.
This is a great feature and is greatly needed when validating JSON Patch documents but its' discoverability is pretty low. It would be great if sample code for it could be added to the article.
---
#### Document Details
⚠ *Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.*
* ID: 593f528c-61b9-7021-335d-c1c0ec1814d1
* Version Independent ID: 6a88d237-1a03-b865-e3c5-20ceedef2a1f
* Content: [JsonPatch in ASP.NET Core web API](https://learn.microsoft.com/en-us/aspnet/core/web-api/jsonpatch?view=aspnetcore-7.0)
* Content Source: [aspnetcore/web-api/jsonpatch.md](https://github.com/dotnet/AspNetCore.Docs/blob/main/aspnetcore/web-api/jsonpatch.md)
* Product: **aspnet-core**
* Technology: **aspnetcore-webapi**
* GitHub Login: @Rick-Anderson
* Microsoft Alias: **riande**
Contributor guide
Assessment
This issue has not been assessed yet.