lib0
lib0 copied to clipboard
array become object after encode/decode
I found that the statement data instanceof Array in encoding.js is incorrect when checking arrays across iframe, which expected to be true.
Maybe Array.isArray is preferred?
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/isArray#instanceof_vs_isarray