elixirschool / school_house

The new era of Elixir School now powered by @phoenixframework
https://elixirschool.com/
Apache License 2.0
155 stars 49 forks source link

Stray end tags h2 and h3 #166

Closed jaimeiniesta closed 3 years ago

jaimeiniesta commented 3 years ago

Our main HTML issues right now are related to stray end tags for h2 and h3 and others, as per this report:

https://rocketvalidator.com/s/756478bb-7472-42d3-b1e2-720c28a0a962/i?search=Stray+end+tag&page=1&non_doc=false

In this report you can get details of where this issue is exactly happening, but for example see the HTML source for:

https://elixirschool.com/de/lessons/basics/basics

Captura de pantalla 2021-10-15 a las 12 29 52

As you see there are duplicated <h2> and <h3> there.

Also note that https://rocketvalidator.com can now be used without an account, I hope it helps in finding HTML and Accessibility issues that need attention :)

jaimeiniesta commented 3 years ago

I've investigated this a bit more and the duplicate ending tag for </h2> and </h3> can be found in the parsed lessons, for example:

SchoolHouse.Lessons.get("basics", "enum", "en")

In the following screenshot, the parsed lesson has a duplicate tag for h2 (and also for h3):

Captura de pantalla 2021-10-18 a las 9 18 52

The original markdown content seems to be fine, but somewhere in the lesson parsing these end tags are being duplicated.

vclayton commented 3 years ago

I think I can fix this. I'll start from your existing jaime-fix-lesson-parsing branch.

jaimeiniesta commented 3 years ago

This issue has been fixed on the latest deploy after #169

Thanks @vclayton @doomspork ! 💪 🚀