!Deprecated notice:

Courses have been deprecated. Now there won't be any more courses on Codeguage. The learning model has now changed from a course-based platform to a practice-based platform. For practice, head over to the page showcasing practiceables.

Short course

JavaScript RegExp

Matching patterns within strings in JavaScript

Intermediate
2 hrs 52 mins
12 chapters

Overview

Regular expressions, or simply regex, is a pattern-matching technology used widely across programming languages with the string data type to carry out complex searching. Regular expressions can be used to find simple to extremely complicated patterns within strings and extract them out in order for further processing.

Where string-based searching finds its stop, regex-based searching finds its start. Regular expressions are extremely powerful, useful and time-saving. Theoretically, they aren't very complicated to understand, however, if not understood the right way, they can quickly become really ugly!

This course teaches you how to work with regular expressions specifically in JavaScript. That is, you'll get to explore the built-in RegExp interface; how to construct regular expressions in JavaScript; how to change between fixed and dynamic expressions; and so on. You will learn a lot of concepts in the way and actually learn regular expressions the right way.

Prerequisites

  • JavaScript

    This course explores regular expressions in JavaScript, likewise knowledge of the core language is required.

Learning outcomes

  • How to construct regular expressions for basic search patterns.
  • How to work with the RegExp interface in JavaScript.
  • How to craft regular expressions leveraging such diverse ideas as character sets, character classes, assertions and boundaries.
  • How to use flags to modify searching behavior to solve a wider array of searching problems.
  • What is grouping and backreferencing, and how they're vital to storing matched portions in a search and then operating on them.
  • How to analyze a searching problem and then design a regular expressions to test for it.

Table of contents

Other courses

HTML

A language to define the content and structure of webpages