Skip to content

Releases: markedjs/marked

v14.1.0

26 Aug 04:00
Compare
Choose a tag to compare

14.1.0 (2024-08-26)

Bug Fixes

Features

  • add provideLexer and provideParser hooks (#3424) (447f5af)

v14.0.0

07 Aug 03:37
Compare
Choose a tag to compare

14.0.0 (2024-08-07)

Bug Fixes

BREAKING CHANGES

  • Remove old renderer
  • throw an error if async: false is set when an extension sets async: true

v13.0.3

28 Jul 17:34
Compare
Choose a tag to compare

13.0.3 (2024-07-28)

Bug Fixes

  • fix recursion-like stack overflow error caused by the old render… (#3380) (89af0b8)

v13.0.2

04 Jul 00:10
Compare
Choose a tag to compare

13.0.2 (2024-07-04)

Bug Fixes

v13.0.1

24 Jun 14:54
Compare
Choose a tag to compare

13.0.1 (2024-06-24)

Bug Fixes

v13.0.0

12 Jun 06:10
Compare
Choose a tag to compare

13.0.0 (2024-06-12)

Bug Fixes

  • Fix blockquote code continuation (#3264) (7ab8185)
  • Add parser as a property on the Renderer object (#3291)
  • Send block text tokens to the text renderer (#3291)

Features

  • Send token objects to renderers (#3291) (1ce59ea)
  • Add space renderer that returns empty string by default (#3291)
  • Add header and align properties to TableCell token (#3291)
  • Add TableRow token (#3291)
  • Add Checkbox token (#3291)

BREAKING CHANGES

  • Add space token after blockquote and hr if there are multiple newlines
  • Send token objects to renderers and move logic to parse tokens from the parser to the renderers.
    • Most extensions that update marked renderers should still work with this version but will break in a future major version.

    • Extensions that change marked renderers will need to be updated and use new option useNewRenderer and accept a token object instead of multiple parameters. See updated Renderer docs

      // v12 renderer extension
      
      const extension = {
        renderer: {
          heading(text, level) {
            // increase level by 1
            return `<h${level + 1}>${text}</h${level + 1}>`;
          }
        }
      };
      
      marked.use(extension);
      // v13 renderer extension
      
      const extension = {
        useNewRenderer: true,
        renderer: {
          heading(token) {
            // increase depth by 1
            const text = this.parser.parseInline(token.tokens);
            const level = token.depth;
            return `<h${level + 1}>${text}</h${level + 1}>`;
          }
        }
      };
      
      marked.use(extension);

v12.0.2

19 Apr 05:13
Compare
Choose a tag to compare

12.0.2 (2024-04-19)

Bug Fixes

v12.0.1

06 Mar 07:43
Compare
Choose a tag to compare

12.0.1 (2024-03-06)

Bug Fixes

v12.0.0

03 Feb 16:27
Compare
Choose a tag to compare

12.0.0 (2024-02-03)

Bug Fixes

BREAKING CHANGES

  • changes to spec
  • Update HTML block tags: add search, remove source
  • Update punctuation to include unicode punctuation and symbol categories
  • Update HTML comment to include <!--> and <!--->

v11.2.0

27 Jan 00:32
Compare
Choose a tag to compare

11.2.0 (2024-01-27)

Bug Fixes

Features