ultramarked
Advanced tools
Comparing version 1.0.2 to 1.0.3
@@ -10,3 +10,3 @@ { | ||
}, | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"repository": { | ||
@@ -22,2 +22,3 @@ "type": "git", | ||
"highlight.js": "^8.0.0", | ||
"lodash.assign": "^2.4.1", | ||
"marked": "^0.3.2" | ||
@@ -24,0 +25,0 @@ }, |
@@ -5,2 +5,3 @@ 'use strict'; | ||
var hljs = require('highlight.js'); | ||
var assign = require('lodash.assign'); | ||
var exports = module.exports = ultramarked; | ||
@@ -25,17 +26,2 @@ var alises = exports.aliases = { | ||
function merge(obj) { | ||
var i = 1, target, key; | ||
for(; i < arguments.length; i++){ | ||
target = arguments[i]; | ||
for(key in target){ | ||
if(Object.prototype.hasOwnProperty.call(target, key)){ | ||
obj[key] = target[key]; | ||
} | ||
} | ||
} | ||
return obj; | ||
} | ||
function getHighlightingRenderer (prev) { | ||
@@ -60,3 +46,3 @@ var renderer = prev || new marked.Renderer(); | ||
function ultramarked(src, opt) { | ||
var options = merge({}, marked.defaults, opt), | ||
var options = assign({}, marked.defaults, opt), | ||
aliases = options.aliases || exports.aliases, | ||
@@ -99,5 +85,4 @@ no = 'no-highlight'; | ||
}else if(options.sanitizer){ | ||
result = options.sanitizer(result); | ||
result = options.sanitizer(result, options); | ||
} | ||
return result; | ||
@@ -104,0 +89,0 @@ } |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
51743
7
525
+ Addedlodash.assign@^2.4.1
+ Addedlodash._basebind@2.4.1(transitive)
+ Addedlodash._basecreate@2.4.1(transitive)
+ Addedlodash._basecreatecallback@2.4.1(transitive)
+ Addedlodash._basecreatewrapper@2.4.1(transitive)
+ Addedlodash._createwrapper@2.4.1(transitive)
+ Addedlodash._isnative@2.4.1(transitive)
+ Addedlodash._objecttypes@2.4.1(transitive)
+ Addedlodash._setbinddata@2.4.1(transitive)
+ Addedlodash._shimkeys@2.4.1(transitive)
+ Addedlodash._slice@2.4.1(transitive)
+ Addedlodash.assign@2.4.1(transitive)
+ Addedlodash.bind@2.4.1(transitive)
+ Addedlodash.identity@2.4.1(transitive)
+ Addedlodash.isfunction@2.4.1(transitive)
+ Addedlodash.isobject@2.4.1(transitive)
+ Addedlodash.keys@2.4.1(transitive)
+ Addedlodash.noop@2.4.1(transitive)
+ Addedlodash.support@2.4.1(transitive)