~/talk

JavaScript ♥ Unicode

Talkat DEVit 2015 · on Friday, 2015-05-15· [javascript]
slides:none on file

JavaScript treats Unicode astral code points as surrogate pairs so .length and naive split/reverse return wrong results, which breaks things like Twitter’s old counter (emoji counted as two) and can even corrupt data. ES2015 adds exact fixes: \u{...} escapes, String.fromCodePoint, string iterators (and the spread operator) and codePointAt, plus normalization (NFC) to collapse equivalent forms. For regexes use the new u flag or build patterns with tools like regenerate; a transpiler rewrites u‑flag regexes for older engines.

AI-written summary · about

  1. 0:00Introduction and speaker intro
  2. 0:37About the presenter
  3. 1:59JavaScript Unicode challenges
  4. 3:46Unicode basics for JavaScript
  5. 7:21Character encodings overview
  6. 10:33Escape sequences in JavaScript
  7. 14:27Surrogate pairs explained
  8. 18:20Counting code points accurately
  9. 23:59Reversing strings with Unicode
  10. 26:52Creating strings from code points
  11. 29:43Iterating over Unicode strings
  12. 30:03Regex dot operator limitations
  13. 34:40Regex character class ranges
  14. 37:51Summary and workarounds
  15. 38:55Q&A session
~/search
type to search 8,222 conferences, 162,397 speakers and 219,688 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
← →
on a talk: 5 seconds back / forward
0–9
on a talk: jump to 0%–90% of the recording
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.