summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorJuan Monetta <jpmonettas@gmail.com>2017-07-07 19:13:01 -0300
committerBozhidar Batsov <bozhidar.batsov@gmail.com>2017-07-08 21:05:38 +0300
commitff4c0ed9bc70c3f48ad74d08c9f7c97e91b2553c (patch)
tree9cbcaaa448641778cf8d8434ca94ad23ec226ac4 /doc
parentde973bd444f9e0e4fd5e3f930a9d991c2e0c047f (diff)
Add a section in the manual for the spec browser
Diffstat (limited to 'doc')
-rw-r--r--doc/images/spec_browser.pngbin0 -> 73955 bytes
-rw-r--r--doc/images/spec_browser_all.pngbin0 -> 129972 bytes
-rw-r--r--doc/images/spec_browser_gen_example.pngbin0 -> 156391 bytes
-rw-r--r--doc/miscellaneous_features.md30
4 files changed, 30 insertions, 0 deletions
diff --git a/doc/images/spec_browser.png b/doc/images/spec_browser.png
new file mode 100644
index 00000000..1ea986b0
--- /dev/null
+++ b/doc/images/spec_browser.png
Binary files differ
diff --git a/doc/images/spec_browser_all.png b/doc/images/spec_browser_all.png
new file mode 100644
index 00000000..a6e5867d
--- /dev/null
+++ b/doc/images/spec_browser_all.png
Binary files differ
diff --git a/doc/images/spec_browser_gen_example.png b/doc/images/spec_browser_gen_example.png
new file mode 100644
index 00000000..e81ce766
--- /dev/null
+++ b/doc/images/spec_browser_gen_example.png
Binary files differ
diff --git a/doc/miscellaneous_features.md b/doc/miscellaneous_features.md
index 36b00142..e9f90aa7 100644
--- a/doc/miscellaneous_features.md
+++ b/doc/miscellaneous_features.md
@@ -193,6 +193,36 @@ Keyboard shortcut | Description
<kbd>n</kbd> | Go to next line.
<kbd>p</kbd> | Go to previous line.
+## Spec browser
+
+If you are using Clojure 1.9.0-alpha16 or newer you can browse the Clojure specs registry.
+
+If you know what you are looking for, you can type <kbd>M-x</kbd> `cider-browse-spec`.
+It will prompt you for a spec name to browse to, hit <kbd>RET</kbd> and you will find yourself
+at the spec browser.
+
+![Spec Browser](images/spec_browser.png)
+
+You can also type the command <kbd>M-x</kbd> `cider-browse-spec-all`. This command will prompt you for
+a regex you can use to filter out the specs you are interested in, and will also take you to the spec browser.
+
+![Spec Browser](images/spec_browser_all.png)
+
+Once in the browser you can use your mouse or the keybindings below to navigate deeper into sub specs.
+
+Keyboard shortcut | Description
+--------------------------------|-------------------------------
+<kbd>RET</kbd> | Browse the spec at point.
+<kbd>^</kbd> | Go up in the navigation stack.
+<kbd>n</kbd> | Go to next spec.
+<kbd>p</kbd> | Go to previous spec.
+<kbd>e</kbd> | Generate an example for the current browser spec.
+
+If your project contains a version of `org.clojure/test.check`, you can type <kbd>e</kbd> when browsing
+a spec to generate and print an example of it.
+
+![Spec Browser Example](images/spec_browser_gen_example.png)
+
## Documentation buffers include "See Also" references
You can add references to other vars by including their names in `` ` `` in the docstring.