Code Review

As secure as typing it in.  Since you are just accessing it via your own JS, which any one could do in the console, it's OK.  If you were sending it to some server, we'd need to talk.