Comparing version 2.2.0 to 2.3.0
@@ -178,3 +178,3 @@ var attrToProp = require('hyperscript-attribute-to-property') | ||
reg += c | ||
} else if (state === ATTR && /[\w-]/.test(c)) { | ||
} else if (state === ATTR && /[^\s"'=/]/.test(c)) { | ||
state = ATTR_KEY | ||
@@ -181,0 +181,0 @@ reg = c |
{ | ||
"name": "hyperx", | ||
"version": "2.2.0", | ||
"version": "2.3.0", | ||
"description": "tagged template string virtual dom builder", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -65,1 +65,13 @@ var test = require('tape') | ||
}) | ||
test('strange leading character attributes', function (t) { | ||
var tree = hx`<div @click='test' :href='/foo'></div>` | ||
t.equal(vdom.create(tree).toString(), '<div @click="test" :href="/foo"></div>') | ||
t.end() | ||
}) | ||
test('strange inbetween character attributes', function (t) { | ||
var tree = hx`<div f@o='bar' b&z='qux'></div>` | ||
t.equal(vdom.create(tree).toString(), `<div f@o="bar" b&z="qux"></div>`) | ||
t.end() | ||
}) |
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
33970
876