Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Being a Firefox user, I have set dom.event.contextmenu.enabled and dom.event.clipboardevents.enabled set to false, so that I can continue right-clicking and pasting.


I recommend checking out the "Don't F$#k with Paste" extension which allows you to essentially control the setting per site: https://addons.mozilla.org/firefox/addon/don-t-fuck-with-pas...

There is also a version for Chrome: https://chrome.google.com/webstore/detail/dont-fuck-with-pas...

EDIT: Made the link locale independent and censored the name better.


If you are on macOS, I have two Services I use to get around these.

Paste as Keyed Characters types in the contents of the clipboard for you [0].

Paste AlphaNumeric Only will only paste in letters and numbers from the clipboard [1]. Very useful when pasting contact phone numbers into forms that only allow numbers.

[0] https://gitlab.com/snippets/1988681

[1] https://gitlab.com/snippets/1988680


Is there a way to quickly toggle those on and off?


I'm not sure if it's the same thing, but usually, holding shift while right clicking enables the context menu in Firefox.


Why do you need to toggle them? Isn't pasting and right clicking useful everywhere?


Some SPAs and other sites have useful right click actions that I want to preserve. Does this setting disable those?

(For the pasting, I agree with you. I can't think of a single reason I'd want a website to prevent me from pasting)


You do not end up losing those. Both the popup menus - the site's as well as the browser's - are shown, the latter on top of the former. Press Esc to make your browser's vanish, and you still have the site's available.


Thanks. I just toggled both of those settings.


I thought some complex web app (editor like) supports copying and pasting complex non-text structure.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: