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

min-document

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

min-document - npm Package Compare versions

Comparing version 1.0.2 to 1.0.3

4

dom-text.js

@@ -17,1 +17,5 @@ module.exports = DOMText

}
DOMText.prototype.replaceData = function replaceData(value) {
this.data = value
}

2

package.json
{
"name": "min-document",
"version": "1.0.2",
"version": "1.0.3",
"description": "A minimal DOM implementation",

@@ -5,0 +5,0 @@ "keywords": [],

@@ -33,5 +33,9 @@ var test = require("tape")

assert.equal(frag.nodeType, 11)
var h1 = document.createElement("h1")
var h2 = document.createElement("h2")
assert.equal(h1.nodeType, 1)
assert.equal(h1.nodeType, 1)

@@ -87,1 +91,15 @@ frag.appendChild(h1)

test("can create/manipulate textnodes", function (assert) {
var textnode = document.createTextNode("hello")
assert.equal(textnode.nodeType, 3)
assert.equal(textnode.data, "hello")
assert.equal(typeof textnode.replaceData, "function")
textnode.replaceData("goodbye")
assert.equal(textnode.nodeType, 3)
assert.equal(textnode.data, "goodbye")
assert.equal(typeof textnode.replaceData, "function")
assert.end()
})
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