clientnode 4.0.1419 → 4.0.1420
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/package.json +2 -2
- package/readme.md +34 -8
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "clientnode",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.1420",
|
|
4
4
|
"description": "Handy utilities for any JavaScript environments.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"client",
|
|
@@ -97,7 +97,7 @@
|
|
|
97
97
|
"prop-types": "^15.8.1",
|
|
98
98
|
"rimraf": "^6.1.3",
|
|
99
99
|
"typescript-eslint": "^8.60.1",
|
|
100
|
-
"web-documentation": "^1.0.
|
|
100
|
+
"web-documentation": "^1.0.29",
|
|
101
101
|
"weboptimizer": "^3.0.24",
|
|
102
102
|
"webpack-dev-server": "^5.2.4"
|
|
103
103
|
},
|
package/readme.md
CHANGED
|
@@ -86,13 +86,25 @@ npm install clientnode
|
|
|
86
86
|
<!--showExample-->
|
|
87
87
|
|
|
88
88
|
```HTML
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
89
|
+
<script src="https://unpkg.com/clientnode@latest/dist/bundle/index.js">
|
|
90
|
+
</script>
|
|
91
|
+
|
|
92
|
+
<div id="first-example-playground"></div>
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
<!--showExample:JavaScript-->
|
|
96
|
+
|
|
97
|
+
```JavaScript
|
|
98
|
+
const domNode = clientnode.createDomNodes('<p>some content to animate</p>');
|
|
99
|
+
|
|
100
|
+
const endless = () => {
|
|
101
|
+
clientnode.fadeIn(domNode)
|
|
102
|
+
.then(() => clientnode.fadeOut(domNode))
|
|
103
|
+
.then(endless)
|
|
104
|
+
};
|
|
105
|
+
endless();
|
|
106
|
+
|
|
107
|
+
document.querySelector('#first-example-playground').appendChild(domNode);
|
|
96
108
|
```
|
|
97
109
|
|
|
98
110
|
The compiled bundle supports AMD, commonjs, commonjs2 and variable injection
|
|
@@ -113,6 +125,20 @@ Execute a JSON based expression:
|
|
|
113
125
|
|
|
114
126
|
<!--showExample-->
|
|
115
127
|
|
|
128
|
+
```HTML
|
|
129
|
+
<div id="second-example-playground"></div>
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
<!--showExample:JavaScript-->
|
|
133
|
+
|
|
116
134
|
```JavaScript
|
|
117
|
-
|
|
135
|
+
document.querySelector('#second-example-playground').innerText =
|
|
136
|
+
clientnode.evaluateExpression(
|
|
137
|
+
{
|
|
138
|
+
$operator: '+',
|
|
139
|
+
operand1: 2,
|
|
140
|
+
operand2: {$select: 'some.data.in.scope'}
|
|
141
|
+
},
|
|
142
|
+
{some: {data: {in: {scope: 3}}}}
|
|
143
|
+
);
|
|
118
144
|
```
|