Skip to main content

Adding queries

await this.query.add(query, maxLvl)

await this.query.add(query, maxLvl)

Adding a new query (query) with the option to optionally specify the maximum level (maxLvl), similar to $tools.query.add

You can pass a hash with parameters as the query, works similarly to Query Builder

Example:

this.query.add({
query: "http://site.com",
param1: "..",
...
});

Example of adding a query at a specific level:

this.query.add({
query: "http://site.com",
lvl: 5,
...
});