a strategy for over-writing transformations
see tests for examples.
opts Object (optional) can have properties:
- identity
- define the identity transformation for this strategy
- default {}
- reifiedIdentity
- define with reify(identity) resolves to
- default null,
- valueSchema Object
- add a JSON-schema to validate the values which are allowed to be passed in
- default (see code, allows string / object / boolean / number)
where:
- graph is a @tangle/graph instance
- nodeIds is an Array of nodeIds you're wanting to check for conflict
- field String is the data field node.data[field] you're checking for conflicts
where:
- graph is a @tangle/graph instance
- mergeNode is the proposed merge-node
- field String is the data field node.data[field] you're checking for merge validity
similar to isValidMerge, but return a transformation, T
If it cannot, an error is thrown!
---
Used with modules such as:
- @tangle/strategy
- ssb-crut