import { Deep } from "https://deno.land/x/rimbu@1.2.1/deep/mod.ts";
const { patch } = Deep;
Returns an immutably updated version of the given value
where the given patchItems
have been
applied to the result.
The Rimbu patch notation is as follows:
- if the target is a simple value or array, the patch can be the same type or a function returning the same type
- if the target is a tuple (array of fixed length), the patch be the same type or an object containing numeric keys with patches indicating the tuple index to patch
- if the target is an object, the patch can be the same type, or an array containing partial keys with their patches for the object