Major Changes
-
#3420 by @zbeyens –
createTEditor
:- Implement default methods for
slate-react
andslate-history
increateTEditor
- Add
noop
function to provide default implementations for unimplemented editor methods
Types:
- Merge
ReactEditor
andHistoryEditor
interfaces intoTEditor
, removingTReactEditor
andTHistoryEditor
- Remove
Value
generic type parameter from function signatures and type definitions - Replace
V extends Value
withE extends TEditor
for improved type inference - Simplify
TEditor<V>
toTEditor
in many places - Refactor element-related types, where
E extends TEditor
in all cases:EElement<V>
toElementOf<E>
EText<V>
toTextOf<E>
ENode<V>
toNodeOf<E>
EDescendant<V>
toDescendantOf<E>
EAncestor<V>
toAncestorOf<E>
EElementOrText<V>
toElementOrTextOf<E>
- Update
TNodeEntry
related types:ENodeEntry<V>
toNodeEntryOf<E>
EElementEntry<V>
toElementEntryOf<E>
ETextEntry<V>
toTextEntryOf<E>
EAncestorEntry<V>
toAncestorEntryOf<E>
EDescendantEntry<V>
toDescendantEntryOf<E>
- Remove unused types:
EElementEntry<V>
ETextEntry<V>
EDescendantEntry<V>
- Implement default methods for