# Consult-org-roam - Completion and preview with consult

**URL:** https://org-roam.discourse.group/t/consult-org-roam-completion-and-preview-with-consult/2512
**Category:** Development
**Created:** [March 13, 2022, 7:04am UTC](https://org-roam.discourse.group/t/consult-org-roam-completion-and-preview-with-consult/2512 "2022-03-13T07:04:12Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![jgru](https://avatars.discourse-cdn.com/v4/letter/j/3ab097/32.png) [@jgru](https://org-roam.discourse.group/u/jgru)
#### Post date: [March 13, 2022, 7:04am UTC](https://org-roam.discourse.group/t/consult-org-roam-completion-and-preview-with-consult/2512/1 "2022-03-13T07:04:12Z")

</div>

Hello everyone,

since I really like `consults` and its preview feature, I decided to create an extension/adapter for `org-roam` to use it. Besides adding some convenience methods, like grepping for content with `consult-grep` (or `consult-ripgrep`) and searching for roam-files, `org-roam`'s competing-read-functions (`org-roam-node-read` and `org-roam-ref-read`) are overridden with equivalent functions using `consult--read`. For my use cases this works well so far.

The code is hosted here:

> **[GitHub - jgru/consult-org-roam: A bunch of convenience functions for...](https://github.com/jgru/consult-org-roam)**
>
> A bunch of convenience functions for operating org-roam with the help of consult - GitHub - jgru/consult-org-roam: A bunch of convenience functions for operating org-roam with the help of consult

What do you think of this approach? Do you have any remarks how to improve it?  
Do you see any drawbacks doing it this way?

Best regards,  
jgru

---

<div class="post-metadata">

### Author: ![artelse](https://avatars.discourse-cdn.com/v4/letter/a/b9bd4f/32.png) [@artelse](https://org-roam.discourse.group/u/artelse)
#### Post date: [March 14, 2022, 4:01pm UTC](https://org-roam.discourse.group/t/consult-org-roam-completion-and-preview-with-consult/2512/2 "2022-03-14T16:01:15Z")

</div>

Great addition to org-roam. I just posted on the GH repo the suggestion to stick with naming conventions and change the name to `consult-org-roam`.

---

<div class="post-metadata">

### Author: ![jgru](https://avatars.discourse-cdn.com/v4/letter/j/3ab097/32.png) [@jgru](https://org-roam.discourse.group/u/jgru)
#### Post date: [March 14, 2022, 7:44pm UTC](https://org-roam.discourse.group/t/consult-org-roam-completion-and-preview-with-consult/2512/3 "2022-03-14T19:44:52Z")

</div>

Thanks for getting back to me and suggesting to change the name.  
I changed the repo’s name and the code base to `consult-org-roam`, so that it’s conforming with consult’s naming scheme.

Best regards,  
jgru

---

<div class="post-metadata">

### Author: ![jgru](https://avatars.discourse-cdn.com/v4/letter/j/3ab097/32.png) [@jgru](https://org-roam.discourse.group/u/jgru)
#### Post date: [March 15, 2022, 1:05pm UTC](https://org-roam.discourse.group/t/consult-org-roam-completion-and-preview-with-consult/2512/4 "2022-03-15T13:05:52Z")

</div>

Do you guys think that the package is valuable addition and should be put up on Melpa?

Best regards,  
jgru

---

<div class="post-metadata">

### Author: ![artelse](https://avatars.discourse-cdn.com/v4/letter/a/b9bd4f/32.png) [@artelse](https://org-roam.discourse.group/u/artelse)
#### Post date: [March 15, 2022, 2:43pm UTC](https://org-roam.discourse.group/t/consult-org-roam-completion-and-preview-with-consult/2512/5 "2022-03-15T14:43:47Z")

</div>

Yes, definitely! 🙂

---

<div class="post-metadata">

### Author: ![jgru](https://avatars.discourse-cdn.com/v4/letter/j/3ab097/32.png) [@jgru](https://org-roam.discourse.group/u/jgru)
#### Post date: [March 25, 2022, 1:39pm UTC](https://org-roam.discourse.group/t/consult-org-roam-completion-and-preview-with-consult/2512/6 "2022-03-25T13:39:29Z")

</div>

FYI: I submitted the package to Melpa and wait for review from their side now. For details, see [here](https://github.com/melpa/melpa/pull/7968)  
Furthermore, I added some features like selectively disabling preview for certain functions.

Best regards,  
jgru
