Socket
Socket
Sign inDemoInstall

markdown-it

Package Overview
Dependencies
Maintainers
1
Versions
79
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

markdown-it - npm Package Compare versions

Comparing version 12.0.3 to 12.0.4

7

CHANGELOG.md

@@ -9,2 +9,8 @@ # Changelog

## [12.0.4] - 2020-12-20
### Fixed
- Fix crash introduced in `12.0.3` when processing strikethrough (`~~`) and similar plugins, #742.
- Avoid fenced token mutation, #745.
## [12.0.3] - 2020-12-07

@@ -549,2 +555,3 @@ ### Fixed

[12.0.4]: https://github.com/markdown-it/markdown-it/compare/12.0.3...12.0.4
[12.0.3]: https://github.com/markdown-it/markdown-it/compare/12.0.2...12.0.3

@@ -551,0 +558,0 @@ [12.0.2]: https://github.com/markdown-it/markdown-it/compare/12.0.1...12.0.2

3

lib/renderer.js

@@ -63,3 +63,3 @@ /**

// If language exists, inject class gently, without modifying original token.
// May be, one day we will add .clone() for token and simplify this part, but
// May be, one day we will add .deepClone() for token and simplify this part, but
// now we prefer to keep things local.

@@ -73,2 +73,3 @@ if (info) {

} else {
tmpAttrs[i] = tmpAttrs[i].slice();
tmpAttrs[i][1] += ' ' + options.langPrefix + langName;

@@ -75,0 +76,0 @@ }

@@ -32,2 +32,6 @@ // For each opening emphasis-like marker find a matching closing one

openerIdx = closerIdx - closer.jump - 1;
// avoid crash if `closer.jump` is pointing outside of the array, see #742
if (openerIdx < -1) openerIdx = -1;
newMinOpenerIdx = openerIdx;

@@ -34,0 +38,0 @@

@@ -35,4 +35,4 @@ // ~~strike through~~

marker: marker,
length: 0, // disable "rule of 3" length checks meant for emphasis
jump: i,
length: 0, // disable "rule of 3" length checks meant for emphasis
jump: i / 2, // for `~~` 1 marker = 2 characters
token: state.tokens.length - 1,

@@ -39,0 +39,0 @@ end: -1,

{
"name": "markdown-it",
"version": "12.0.3",
"version": "12.0.4",
"description": "Markdown-it - modern pluggable markdown parser.",

@@ -5,0 +5,0 @@ "keywords": [

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc