4 ms·
Fork the Don't Fuck with paste code and add that feature (or use it as an example to make your "Don't fuck with copy" extension). https://github.com/jswanner/D
by thebouv 9y ago
Fork the Don't Fuck with paste code and add that feature (or use it as an example to make your "Don't fuck with copy" extension).
https://github.com/jswanner/DontFuckWithPaste https://github.com/jswanner/DontFuckWithPaste
I hate sites that do that (or prevent right-click as if that somehow secures their code).
- majewsky 9y agoI'd actually like an extension along the lines of "This is not Google Docs, for fuck's sake", that just disables all these APIs that are only ever useful with rich apps, but not with content-heavy websites, for example: - copy/paste hijacking - sensor access: microphone, camera, GPS, etc. Maybe even go further and introduce some sort of rate-limiting for - XHR requests - relayout events to save power and data.
- artursapek 9y agoIncidentally, what are these APIs? I am building a rich content app (SVG editor) and have been starting to think about what copy + paste will look like.
- akubera 9y agoI think you want to investigate the "ClipboardEvent" web API. Try starting here: https://developer.mozilla.org/en-US/docs/Web/API/ClipboardEvent https://developer.mozilla.org/en-US/docs/Web/API/ClipboardEv...
- artursapek 9y agoThanks!
- ben_jones 9y agoCouldn't you just load a JS file before 3rd party scripts and overload those methods? Preferably in a way that won't break the site.