@elastic.io/jsonata-moment
v1.1.6
Published
Moment support for JSONata
Downloads
978
Readme
jsonata-moment
Moment.js support for JSONata.
How to install
npm install @elastic.io/jsonata-moment
Usage
$moment
function provides the same functionality, as regular moment()
does.
In node.js
const jsonataMoment = require('@elastic.io/jsonata-moment');
const result = jsonataMoment('$moment().format("YYYY-MM-DD")').evaluate();
In browser
There is a regular as well as minified versions of the library in a dist
folder.
const result = window.jsonataMoment('$moment().format("YYYY-MM-DD")').evaluate();