ViewUpdate type confusion

When I use

EditorView.updateListener.of((update) => {})

update is typed as ViewUpdate

When I console log update.transactions[0] I see a Transaction object with an annotations array.

However the Transaction type doesn’t specify that array.

Should update be another type?

Objects may have undocumented/unexported properties. Just don’t use those, and you’ll be fine.

1 Like