syntaxe
v1.3.4
Published
A declarative data querying library inspired by graphql.
Downloads
18
Maintainers
Readme
Syntaxe is a data query library inspired by graphql.
Syntaxe, with the help of a schema and a variety of operators, can be used to perform any number of query operations on most types of data e.g. String, Object or Array.
Installation
Setup 💾
npm install syntaxe
Example
A basic example (ES Modules)
import Syntaxe from "syntaxe";
const sx = new Syntaxe({
data: [1,2,3],
schema: `[size]`
});
const result = await sx.query();
// Result: 3
// OR
sx.query().then((result) => {});
// Result: 3
A basic example (CommonJs)
const Syntaxe = require("syntaxe");
const sx = new Syntaxe({
data: [1,2,3],
schema: `[size]`
});
sx.query().then((result) => {});
// Result: 3
Support and Feedback
If you find any bugs or inconsistency, please submit an issue here in GitHub.
If you have any issues using the library, please contact me by email [email protected] with the subject 'Problem Using Syntaxe'.
You are welcome to contribute or participate in making the library better.
NOTE: Development of this library in various technologies, including PHP, C#, Java, Python, and others, is currently underway, with support for both standalone and REST API usage.