Hacker News new | ask | show | jobs
by olliej 1858 days ago
You need it for google docs, etc to intercept paste events and do the right thing from the perspective of a document editor.

But this also illustrates the fact that "useful" browser features can be trivially abused.

1 comments

That's an interesting point. I could see the feature looking like:

- Allowing a page to intercept a paste.

- If the page doesn't modify the DOM in response, then override it and actually paste the content.

Still trivial to bypass.
Maybe, but it might block the common case of "well intentioned developer breaks the built-in functionality without realizing it".
Is that really a common case when paste is disabled? I can't recall ever coming across it where it wasn't obvious that it was intentional.
That may be true. Maybe instead we could have a menu like

- Copy

- Paste

- No, really, paste the darn text