Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

RegExp.prototype.unicode - How ES6 Makes JavaScript Regular Expressions Unicode-Aware

JSConf via YouTube

Overview

Save Big on Coursera Plus. 7,000+ courses at $160 off. Limited Time Only!
Explore the intricacies of Unicode in JavaScript regular expressions in this JSConf EU 2015 talk by Mathias Bynens. Dive into the challenges developers face with Unicode in ECMAScript 5 and discover how ES6 (ECMAScript 2015) addresses these issues. Learn about the new 'u' flag for regular expressions, its impact on various regex operations, and how it improves Unicode handling. Understand the implications for HTML documents and learn how to transpile ES6 Unicode regular expressions to ES5. Gain insights into matching predefined Unicode categories, scripts, and blocks. By the end of this 25-minute presentation, acquire the knowledge to create Unicode-aware regular expressions in JavaScript with confidence, enhancing your ability to handle international user input and perform accurate string manipulation.

Syllabus

Intro
Quick intro to Unicode
The ES6 u flag for regular expressions
Unicode code point escapes
u flag disallows useless backslash escapes
Impact on the operator
Impact on character classes
Impact on character class escapes
Impact on the i flag
Impact on HTML documents
Support for the u flag
Transpiling E56 Unicode regular expressions to ES5
regexpu internals
Matching predefined Unicode categories/scripts/blocks
Takeaways

Taught by

JSConf

Reviews

Start your review of RegExp.prototype.unicode - How ES6 Makes JavaScript Regular Expressions Unicode-Aware

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.