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

hexo-util

Package Overview
Dependencies
Maintainers
1
Versions
55
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

hexo-util - npm Package Compare versions

Comparing version 0.1.4 to 0.1.5

11

lib/highlight.js
'use strict';
var ent = require('ent');
var hljs;

@@ -76,3 +77,3 @@

var result = {value: str};
var result = {value: ent.encode(str)};
lang = lang.toLowerCase();

@@ -89,7 +90,11 @@

return tryHighlight(str, lang) || result;
}
function tryHighlight(str, lang){
try {
return hljs.highlight(lang, str);
} catch (err){
return result;
return;
}
}
}
{
"name": "hexo-util",
"version": "0.1.4",
"version": "0.1.5",
"description": "Utilities for Hexo.",

@@ -39,4 +39,5 @@ "main": "lib/index",

"bluebird": "^2.6.2",
"ent": "^2.2.0",
"highlight.js": "^8.4.0"
}
}
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