Markdown Previewer solution fails Tests 5 and 6 despite functioning as intended

Edit2: This has been fixed.

Edit: Quick update. We know what is wrong with the tests and they are getting fixed, hopefully soon. After the fix has landed the markedjs library should work again when using the Codepen settings or a script element to load the library. But until then keep using import.


The library has been updated and you now have to use import for Codepen.

Import it at the top of the JS like this.

import { marked } from "https://cdn.skypack.dev/marked@4.0.0";

And remove the script from the JS section in the settings.


As an aside, whenever you see a library bump the major version number, in this case going from 3.x.x to 4.x.x you always have to look for breaking changes. Major version bumps most often imply breaking changes.

releases notes: 4.0.0 (2021-11-02)

7 Likes