New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

md.js

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

md.js - npm Package Compare versions

Comparing version 0.1.4 to 0.1.5

13

md.js

@@ -24,2 +24,5 @@ /*!

var XSSFilterHrefRegExp = /(javascript)[\n\t ]*:/gm;
var XSSFilterHrefTemplate = '#$1:';
var removeWhiteSpaceRegExp = /^[\t ]+|[\t ]$/gm;

@@ -91,3 +94,3 @@

markdown
// convert <script> tags
// XSS script tags
.replace(XSSFilterRegExp, XSSFilterTemplate)

@@ -119,7 +122,5 @@ // collect code blocks and replace with placeholder

// unorderd lists
.replace(listUlRegExp1, listUlTemplate)
.replace(listUlRegExp2, '')
.replace(listUlRegExp1, listUlTemplate).replace(listUlRegExp2, '')
// ordered lists
.replace(listOlRegExp1, listOlTemplate)
.replace(listOlRegExp2, '')
.replace(listOlRegExp1, listOlTemplate).replace(listOlRegExp2, '')
// horizontal rule

@@ -139,2 +140,4 @@ .replace(horizontalRegExp, horizontalTemplate)

.replace(lineBreaksRegExp, lineBreaksTemplate)
// XSS href
.replace(XSSFilterHrefRegExp, XSSFilterHrefTemplate)
);

@@ -141,0 +144,0 @@

@@ -5,3 +5,3 @@ {

"description": "a lightweight markdown parser",
"version": "0.1.4",
"version": "0.1.5",
"homepage": "https://github.com/thysultan/md.js",

@@ -8,0 +8,0 @@ "license": "MIT",

@@ -26,2 +26,3 @@ # MD.js

and `<script>alert(1);</script>` will be converted to `&lt;script&gt;alert(1)&lt;/script&gt;`
and `<a href="javascript:alert('xss')"></a>` will be converted to `<a href="#javascript&#58;alert('xss')"></a>`

@@ -28,0 +29,0 @@ ## Browser Support

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