Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

markdownlint

Package Overview
Dependencies
Maintainers
1
Versions
71
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

markdownlint - npm Package Compare versions

Comparing version 0.14.0 to 0.14.1

14

lib/md033.js

@@ -9,4 +9,9 @@ // @ts-check

const htmlElementRe = /<(\w+)(?:[^>]*)?>/g;
const htmlElementRe = /<(([\w-]+)(?:[\s/][^>]*)?)>/g;
const linkDestinationRe = /]\(\s*$/;
const inlineCodeRe = /^[^`]*(`+[^`]+`+[^`]+)*`+[^`]*$/;
// See https://spec.commonmark.org/0.29/#autolinks
const emailAddressRe =
// eslint-disable-next-line max-len
/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;

@@ -24,7 +29,8 @@ module.exports = {

while (!inCode && (match = htmlElementRe.exec(line))) {
const [ tag, element ] = match;
const [ tag, content, element ] = match;
if (!allowedElements.includes(element.toLowerCase()) &&
!tag.endsWith("\\>") && !bareUrlRe.test(tag)) {
!tag.endsWith("\\>") && !bareUrlRe.test(content) &&
!emailAddressRe.test(content)) {
const prefix = line.substring(0, match.index);
if (!linkDestinationRe.test(prefix) &&
if (!linkDestinationRe.test(prefix) && !inlineCodeRe.test(prefix) &&
!unescapeMarkdown(prefix + "<", "_").endsWith("_")) {

@@ -31,0 +37,0 @@ addError(onError, lineIndex + 1, "Element: " + element,

{
"name": "markdownlint",
"version": "0.14.0",
"version": "0.14.1",
"description": "A Node.js style checker and lint tool for Markdown/CommonMark files.",

@@ -5,0 +5,0 @@ "main": "lib/markdownlint.js",

@@ -754,2 +754,3 @@ # markdownlint

in-browser demo, update dependencies.
* 0.14.1 - Improve MD033.

@@ -756,0 +757,0 @@ [npm-image]: https://img.shields.io/npm/v/markdownlint.svg

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