@thi.ng/hdom
Advanced tools
Comparing version 2.1.1 to 2.2.0
@@ -6,2 +6,13 @@ # Change Log | ||
<a name="2.2.0"></a> | ||
# [2.2.0](https://github.com/thi-ng/umbrella/compare/@thi.ng/hdom@2.1.1...@thi.ng/hdom@2.2.0) (2018-03-14) | ||
### Features | ||
* **hdom:** add auto deref() support ([0fe6c44](https://github.com/thi-ng/umbrella/commit/0fe6c44)) | ||
<a name="2.1.1"></a> | ||
@@ -8,0 +19,0 @@ ## [2.1.1](https://github.com/thi-ng/umbrella/compare/@thi.ng/hdom@2.1.0...@thi.ng/hdom@2.1.1) (2018-03-08) |
@@ -13,3 +13,3 @@ "use strict"; | ||
let tag = spec[0]; | ||
let hasAttribs = is_plain_object_1.isPlainObject(spec[1]); | ||
let hasAttribs = is_plain_object_1.isPlainObject(spec[1]) && !implements_function_1.implementsFunction(spec[1], "deref"); | ||
if (!is_string_1.isString(tag) || !(match = api_1.TAG_REGEXP.exec(tag))) { | ||
@@ -110,2 +110,5 @@ throw new Error(`${tag} is not a valid tag name`); | ||
} | ||
if (implements_function_1.implementsFunction(el, "deref")) { | ||
return normalizeTree(el.deref(), path.slice(), keys, span); | ||
} | ||
return span ? | ||
@@ -112,0 +115,0 @@ ["span", keys ? { key: path.join("-") } : {}, el.toString()] : |
{ | ||
"name": "@thi.ng/hdom", | ||
"version": "2.1.1", | ||
"description": "TODO", | ||
"version": "2.2.0", | ||
"description": "Lightweight vanilla ES6 UI component & virtual DOM system", | ||
"main": "./index.js", | ||
@@ -11,9 +11,11 @@ "typings": "./index.d.ts", | ||
"scripts": { | ||
"build": "yarn run clean && tsc --declaration", | ||
"clean": "rm -rf *.js *.d.ts build doc", | ||
"build": "yarn clean && tsc --declaration", | ||
"clean": "rm -rf *.js *.d.ts .nyc_output build coverage doc", | ||
"cover": "yarn test && nyc report --reporter=lcov", | ||
"doc": "node_modules/.bin/typedoc --mode modules --out doc src", | ||
"pub": "yarn run build && yarn publish --access public", | ||
"test": "rm -rf build && tsc -p test && mocha build/test/*.js" | ||
"pub": "yarn build && yarn publish --access public", | ||
"test": "rm -rf build && tsc -p test && nyc mocha build/test/*.js" | ||
}, | ||
"devDependencies": { | ||
"@thi.ng/atom": "^0.12.1", | ||
"@types/mocha": "^2.2.48", | ||
@@ -29,3 +31,3 @@ "@types/node": "^9.4.6", | ||
"@thi.ng/diff": "^1.0.1", | ||
"@thi.ng/hiccup": "^1.1.3", | ||
"@thi.ng/hiccup": "^1.2.0", | ||
"@thi.ng/iterators": "^4.0.7" | ||
@@ -32,0 +34,0 @@ }, |
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
45958
579
8
Updated@thi.ng/hiccup@^1.2.0