Compared to Tiptap, Slate seems to perform poorly when pasting large amounts of data.
I generated test data using:
let text = [];
for (let i = 0; i < 10000; i++) {
text.push(`${i} this is a test demo. \n`);
}
let res = text.join('');
console.log(res);
Then I pasted the generated text into Slate (https://www.slatejs.org/examples/plaintext) and Tiptap (https://tiptap.dev/docs/examples/basics/default-text-editor) respectively.
Slate took about 7 seconds to parse the content, while Tiptap only took 1 second.
Are there any ways to optimize this?