v3.0.0
json_patch
JSON 패치 표준을 위한 순수 Dart 유틸리티 패키지입니다. JSON 유사 객체에 대해 패치 작업을 적용하고 차이 알고리즘을 수행할 수 있습니다.
25좋아요 8.7천30일 다운로드140Pub 점수
AndroidiOSWebmacOSWindowsLinux
JSON Patch 표준을 위한 순수 Dart 유틸리티 패키지입니다.
^1.15.0^1.17.5아래는 영문 원문 스냅샷입니다. 최신 내용은 GitHub에서 확인하세요.
A simple utility package for JSON Patch. Includes a simple diff algorithm as well as the ability to apply JSON Patch operations to a JSON-like Dart object.
import 'package:json_patch/json_patch.dart';
...
final ops = JsonPatch.diff(oldJson, newJson);
try {
final patchedJson = JsonPatch.apply(json, patches, strict: false);
} on JsonPatchTestFailedException catch (e) {
print(e);
}
See the example or the API docs for more information.