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

markmap-common

Package Overview
Dependencies
Maintainers
1
Versions
60
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

markmap-common - npm Package Compare versions

Comparing version 0.13.3-alpha.1 to 0.13.3-alpha.2

28

dist/index.esm.js

@@ -1,2 +0,2 @@

/*! markmap-common v0.13.3-alpha.1+f7f5075 | MIT License */
/*! markmap-common v0.13.3-alpha.2+a5a159b | MIT License */
class Hook {

@@ -47,2 +47,18 @@ constructor() {

function _objectWithoutPropertiesLoose(source, excluded) {
if (source == null) return {};
var target = {};
var sourceKeys = Object.keys(source);
var key, i;
for (i = 0; i < sourceKeys.length; i++) {
key = sourceKeys[i];
if (excluded.indexOf(key) >= 0) continue;
target[key] = source[key];
}
return target;
}
const _excluded = ["textContent"];
function escapeHtml(html) {

@@ -83,4 +99,12 @@ return html.replace(/[&<"]/g, m => ({

return items.map(item => {
if (item.type === 'script') return wrapHtml('script', '', item.data);
if (item.type === 'script') {
const _item$data = item.data,
{
textContent
} = _item$data,
rest = _objectWithoutPropertiesLoose(_item$data, _excluded);
return wrapHtml('script', textContent, rest);
}
if (item.type === 'iife') {

@@ -87,0 +111,0 @@ const {

@@ -1,2 +0,2 @@

/*! markmap-common v0.13.3-alpha.1+f7f5075 | MIT License */
/*! markmap-common v0.13.3-alpha.2+a5a159b | MIT License */
'use strict';

@@ -51,2 +51,18 @@

function _objectWithoutPropertiesLoose(source, excluded) {
if (source == null) return {};
var target = {};
var sourceKeys = Object.keys(source);
var key, i;
for (i = 0; i < sourceKeys.length; i++) {
key = sourceKeys[i];
if (excluded.indexOf(key) >= 0) continue;
target[key] = source[key];
}
return target;
}
const _excluded = ["textContent"];
function escapeHtml(html) {

@@ -87,4 +103,12 @@ return html.replace(/[&<"]/g, m => ({

return items.map(item => {
if (item.type === 'script') return wrapHtml('script', '', item.data);
if (item.type === 'script') {
const _item$data = item.data,
{
textContent
} = _item$data,
rest = _objectWithoutPropertiesLoose(_item$data, _excluded);
return wrapHtml('script', textContent, rest);
}
if (item.type === 'iife') {

@@ -91,0 +115,0 @@ const {

4

package.json
{
"name": "markmap-common",
"version": "0.13.3-alpha.1+f7f5075",
"version": "0.13.3-alpha.2+a5a159b",
"description": "",

@@ -27,3 +27,3 @@ "author": "",

},
"gitHead": "f7f507547a2e1b2b1637e532a1c67d6ad0eabaf9"
"gitHead": "a5a159bee156ba7c77cf952f6f0f3e450f8c12fa"
}

@@ -57,3 +57,4 @@ export interface IHierarchy<T> {

data: {
src: string;
src?: string;
textContent?: string;
async?: boolean;

@@ -60,0 +61,0 @@ defer?: boolean;

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