react-markdown v4.0.0 Release Notes

Release Date: 2018-10-02 // over 5 years ago
  • 💥 BREAKING

    • text is now a first-class node + renderer — if you are using allowedNodes, it needs to be included in this list. Since it is now a React component, it will be passed an object of props instead of the old approach where a string was passed. children will contain the actual text string.
    • On React >= 16.2, if no className prop is provided, a fragment will be used instead of a div. To always render a div, pass 'div' as the root renderer.
    • On React >= 16.2, escaped HTML will no longer be rendered with div/span containers
    • The UMD bundle now exports the component as window.ReactMarkdown instead of window.reactMarkdown

    ➕ Added

    • 🔌 HTML parser plugin for full HTML compatibility (Espen Hovlandsdal)

    🛠 Fixes

    • URI transformer allows uppercase http/https URLs (Liam Kennedy)
    • [TypeScript] Strongly type the keys of renderers (Linus Unnebäck)