dynamic-html-helpers 1.5.9 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -40,16 +40,14 @@ function logFactory(formatJSON = true) {
40
40
 
41
41
  return content => {
42
42
  if (content?.isJQx) {
43
- const item = $.li().append(content);
44
- if (content.data.get(`header`)) { item.addClass(`head`); }
43
+ const item = $.li().append(content).addClass(!!content.data.get(`header`) ? `head` : ``);
45
44
  return item.renderTo(logContainer, where2PutIt);
46
45
  }
47
46
 
48
47
  content = !$.IS(content, String, Number, Symbol) ? tryJSON(content, formatJSON) : String(content);
49
48
  const isHead = content.startsWith(`!!`);
50
49
  content = isHead ? content.slice(2) : content;
51
- const item = $.li(content);
52
- isHead && item.addClass(`head`);
50
+ const item = $.li(content).addClass(isHead ? `head` : ``);
53
51
  item.renderTo(logContainer, where2PutIt);
54
52
  };
55
53
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dynamic-html-helpers",
3
- "version": "1.5.9",
3
+ "version": "1.6.0",
4
4
  "description": "Helpers for ES/JS/HTML projects",
5
5
  "keywords": [
6
6
  "es20xx",