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

domify

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

domify - npm Package Compare versions

Comparing version 1.0.0 to 1.1.1

2

component.json
{
"name": "domify",
"version": "1.0.0",
"version": "1.1.1",
"description": "turn HTML into DOM elements",

@@ -5,0 +5,0 @@ "scripts": ["index.js"],

@@ -0,8 +1,18 @@

1.1.1 / 2013-11-05
==================
1.0.0 / 2013-06-13
* use createTextNode() [jkroso]
1.1.0 / 2013-11-05
==================
* do not rely on live .children NodeList [timoxley]
* generate text node if not given an html tag [timoxley]
1.0.0 / 2013-06-13
==================
* return document fragments for multiple top level nodes
0.2.0 / 2013-05-21
0.2.0 / 2013-05-21
==================

@@ -12,3 +22,3 @@

0.1.0 / 2012-10-24
0.1.0 / 2012-10-24
==================

@@ -21,3 +31,3 @@

0.0.3 / 2012-08-28
0.0.3 / 2012-08-28
==================

@@ -27,3 +37,3 @@

0.0.2 / 2012-08-01
0.0.2 / 2012-08-01
==================

@@ -30,0 +40,0 @@

@@ -39,5 +39,7 @@

html = html.replace(/^\s+|\s+$/g, ''); // Remove leading/trailing whitespace
// tag name
var m = /<([\w:]+)/.exec(html);
if (!m) throw new Error('No elements were generated.');
if (!m) return document.createTextNode(html);
var tag = m[1];

@@ -61,10 +63,12 @@

var els = el.children;
if (1 == els.length) {
return el.removeChild(els[0]);
// Note: when moving children, don't rely on el.children
// being 'live' to support Polymer's broken behaviour.
// See: https://github.com/component/domify/pull/23
if (1 == el.children.length) {
return el.removeChild(el.children[0]);
}
var fragment = document.createDocumentFragment();
while (els.length) {
fragment.appendChild(el.removeChild(els[0]));
while (el.children.length) {
fragment.appendChild(el.removeChild(el.children[0]));
}

@@ -71,0 +75,0 @@

{
"name": "domify"
, "version": "1.0.0"
, "description": "turn HTML into DOM elements"
, "keywords": ["dom", "html", "client", "browser", "component"]
, "author": "TJ Holowaychuk <tj@vision-media.ca>"
, "dependencies": {}
, "component": {
"scripts": {
"domify": "index.js"
"name": "domify",
"version": "1.1.1",
"description": "turn HTML into DOM elements",
"keywords": [
"dom",
"html",
"client",
"browser",
"component"
],
"author": "TJ Holowaychuk <tj@vision-media.ca>",
"dependencies": {},
"component": {
"scripts": {
"domify": "index.js"
}
},
"main": "index",
"repository": {
"type": "git",
"url": "https://github.com/component/domify.git"
}
}
, "main": "index"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

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