Home / GitHub Page

Hiding Passwords with Markdown


#1

I love using markdown to organize stuff. The issue is, I store passwords and usernames in some of my notes but I hate having them in clear text in case people are looking over my shoulder. Some markdown websites/plugins have the use of !> to hide text until it’s hovered over with a mouse. Something like that would be great!

C10


#2

You could add something like this to userstyle.css

.hidden {
  background: #000;
  font-color: #000;
  transition: background 0.5s ease;
}

.hidden:hover {
  background: none;
}

And then in your notes you could use it like:

Here is a large block of text with a hidden <span class="hidden">password</span> that is only revealed on hover.

I know it’s not ideal, but you can get this working today as opposed to waiting for someone to implement this as a feature.

P.S. I got most of this code from here


#3

You can also use MD Comment syntax to hide text in the MD Preview.