How do I prevent a query from running automatically when the Slate document loads?

136 views Asked by At

I have a Slate query and I only want it to run when I click on a button, but not before. How do I control this?

1

There are 1 answers

0
amy.bananagrams On

You can set queries to run manually from the query editor.

Press the button next to Run with the down arrow to get the query options, and check the box next to "Run Manually".

Note: If you set a query to run manually, it will not run on document load or when its dependencies change. It will only run when triggered by an Event.

In the Slate documentation, find the section on "Managing Query Execution" with the Slate Development Best Practices guide for more in-depth discussion of patterns for controlling queries.