freeCodeCamp / curriculum

The freeCodeCamp curriculum and lesson editor
Creative Commons Attribution Share Alike 4.0 International
81 stars 125 forks source link

fix(challenges): converts delete html tests to regex #253

Closed joshalling closed 6 years ago

joshalling commented 6 years ago

Description

This code converts the tests of the Delete HTML Elements challenge to use regex instead of jQuery. This prevents some weird behavior as shown below. This change also makes it possible to add a solution to be tested with the test suite so I included that as well.

The following code currently passes, but it will not pass with this change:

Hello World</h1>

<h2>

<p>

My actual changes start on line 568 and go through 587.

Pre-Submission Checklist

Checklist:

Closes #251

scissorsneedfoodtoo commented 6 years ago

Sorry for the delay in reviewing this. Everything LGTM!