JS Flux parser in Rust
npm install @qxip/wasmy_fluxget_treeto parse to AST treeget_syntax_errorto check for parsing error
const { get_syntax_error, get_tree } = require("@qxip/wasmy_flux");
const source = 'from(bucket:"telegraf/aaa") |> limit(limit:100, offset:10)';
if (get_syntax_error(source) == "" ){
console.log(get_tree(source));
} else { console.log(err) }Based on wasmy_rust