From 4bf48ae0c237337a73d2a1529667906dd6e0909b Mon Sep 17 00:00:00 2001 From: Will Hopkins Date: Mon, 3 Jun 2024 12:24:50 -0700 Subject: [PATCH] docs: document `Precognition` command --- README.md | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 310b168..5067069 100644 --- a/README.md +++ b/README.md @@ -64,21 +64,37 @@ Any hints that could appear in the same place as others should have unique prior ## ❔Usage +`precognition` can be controlled with the `Precognition` user command, as well as programmatically via the Lua API. + ### Toggling The hints can be toggled on and off with +```vim +:Precognition toggle ``` -:lua require("precognition").toggle() + +or + +```lua +require("precognition").toggle() ``` +The subcommands and functions `show` and `hide` are also available. + ### Peeking The hints can be peeked, this means that the hint will be show until the next cursor movement. +```vim +:Precognition peek ``` -:lua require("precognition").peek() + +or + +```lua +require("precognition").peek() ``` ## 💻 Supported Versions