How to hide some context menu items?

I’m sorry, this is not, and I’ve already seen “this”. And your snippet doesn’t work by the way, you can’t hide “Help” or “Settings” or “Open another vault”.

What I am looking for is to hide a particular item from your right-click to a folder or a note.

And for hide the icon from the right sidebar Customizable Sidebar is helpful.

It would be best if you tried the snippet I gave above, and you’ll see what exactly what do I mean.