You need utilities for:
- Primitive types
- Arrays
- Functions
- Numbers
- Objects
- Strings
- Date and time
- Mutual exclusion
- Lock management
- Semaphore management
- Backend
- CLIs
- Filesystem
- Processes
- Frontend
- Cookies
- DOM
- Data-Transfer
- JSON-based Expressions
- Logging
- Scopes
- Testing
- Typescript
- URLs
You can install via package manager, simply download the compiled version as zip file here and inject or request via cdn in HTML:
npm install clientnodeimport{createDomNodes,evaluateExpression}from'cientnode'// ...<divid="first-example-playground"></div>import{fadeIn,fadeOut,createDomNodes}from'https://unpkg.com/clientnode@latest/dist/bundle/index.js'constdomNode=createDomNodes('<p>some content to animate</p>')constendless=()=>{fadeIn(domNode).then(()=>fadeOut(domNode)).then(endless)}endless()document.querySelector('#first-example-playground').appendChild(domNode)The compiled bundle supports AMD, commonjs, commonjs2 and variable injection into given context (UMD) as export format: You can use a module bundler if you want.
Execute a JSON based expression:
<divid="second-example-playground"></div>import{evaluateExpression}from'https://unpkg.com/clientnode@latest/dist/bundle/index.js'document.querySelector('#second-example-playground').innerText=evaluateExpression({$operator: '+',operand1: 2,operand2: {$select: 'some.data.in.scope'}},{some: {data: {in: {scope: 3}}}})