Socket
Socket
Sign inDemoInstall

embeds

Package Overview
Dependencies
Maintainers
4
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

embeds - npm Package Compare versions

Comparing version 2.0.1 to 2.1.0

9

dist/parse-input.js

@@ -118,2 +118,11 @@ 'use strict';

};
}], [/https:\/\/embed\.acast\.com\/([\w.-]+)\/([\w.-]+)/, function (match) {
var channel = match[1];
var name = match[2];
return {
type: 'acast',
channel: channel,
name: name,
url: 'https://embed.acast.com/' + channel + '/' + name
};
}]];

@@ -99,2 +99,12 @@ const allowed = [

};
}],
[/https:\/\/embed\.acast\.com\/([\w.-]+)\/([\w.-]+)/, match => {
const channel = match[1];
const name = match[2];
return {
type: 'acast',
channel,
name,
url: `https://embed.acast.com/${channel}/${name}`
};
}]

@@ -101,0 +111,0 @@ ];

2

package.json
{
"name": "embeds",
"version": "2.0.1",
"version": "2.1.0",
"description": "Parse & render embeds",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

@@ -404,1 +404,18 @@ import test from './tape-wrapper';

});
test('acast', t => {
const acastCode = tsml`
<iframe width="540" height="540"
src="https://embed.acast.com/specialrelationship/-1-terrorismandnationalsecurity"
scrolling="no" frameborder="0" style="border:none;overflow:hidden;"></iframe>`;
const expected = {
type: 'acast',
channel: 'specialrelationship',
url: 'https://embed.acast.com/specialrelationship/-1-terrorismandnationalsecurity',
name: '-1-terrorismandnationalsecurity'
};
t.deepEqual(parseInput(acastCode), expected);
t.deepEqual(parseInput('https://embed.acast.com/specialrelationship/-1-terrorismandnationalsecurity'), expected);
});
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