4 ms·
S?he probably listened to the keyup event instead.
by jwandborg 9y ago
S?he probably listened to the keyup event instead.
- Void_ 9y agoHis name is Dan ...
- deleted 9y ago[deleted]
- novium 9y agoStill not a reason to assume things here.
- kupiakos 9y agoShould just default to the singular they then.
- jwandborg 9y agoMy fault. I'm more comfortable with regular expressions than the English language.
- eradicatethots 9y agoIs it just me or is none of this a big deal?
- Moter8 9y agoPeople don't first go to the user profile to look for a name. dangero seems like a random nick
- zbentley 9y agodangero . . . us?
- dan1234 9y agoDan could be short for Danielle or Danika or…
- jen729w 9y agoPeople always assume I’m “Jen”, female, which is often enlightening. They’re my initials.
- jwandborg 9y ago- I did not read their username. - I did not click through to their profile. The cause for both of these is that my mobile HN experience is horrible for me (a lazy person). I spent a few seconds looking for a word to replace "She/He", when none came to mind I fell back to a regular expression[1]. As iaml pointed out[2] (along with others) https://en.wikipedia.org/wiki/Singular_they https://en.wikipedia.org/wiki/Singular_they is the proper solution to this issue, and I will try to remember that in the future. --- [1] as we so often do in our daily lives. [2] https://news.ycombinator.com/item?id=15489652 https://news.ycombinator.com/item?id=15489652 --- In my second attempt at comedy today, Trying to perform the error-prone art of interpreting genders based on usernames, the best I came up with for you is /^\0_$/ Feedback welcome, this is my first attempt at matching null in a regular expression. I'll explain the joke, so that no-one feels left out: I interpret name "Void" as gender "null", then carry the underscore over, using artistic license, to make the regex more interesting.
- Legogris 9y agoYou'd have to listen to both, right? Otherwise it'd be the same issue when the user tabs into the password input rather than out of.
- thomastjeffery 9y agoNo. You could listen for the keydown, but you wouldn't hear it, so you may as well ignore what you can't hear.
- michaelmior 9y agoYou should get a key down event when moving into the password field since you're coming from a field which is not secure.
- dangero 9y agoYes you're right. I made a variable that tracked the current state of keyup keydown and could detect this special case.
- iaml 9y agohttps://en.wikipedia.org/wiki/Singular_they https://en.wikipedia.org/wiki/Singular_they
- jwandborg 9y agoThank you, that is much better than /S?he|\w+kin|.*/ This irrational regular expression is an attempt at comedy. On a serious note, I was looking for that word, but failed to remember it[0]. [0] https://news.ycombinator.com/item?id=15490542 https://news.ycombinator.com/item?id=15490542