Skip to content

Observe cider-doc.edn Java resource files for user-extensible documentation #863

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

vemv
Copy link
Member

@vemv vemv commented Mar 31, 2024

Fixes #861

Just a draft for now, will be trying it out for a while in a real project, but any ideas welcome.

simple-keyword?
string?))

(defn cider-doc-edn-configs []
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TODO - use a cache for not computing the configs every time...

@@ -0,0 +1,2 @@
{[cider-doc-edn-example] {:info-provider cider.nrepl.middleware.info-test/sample-info-provider
:if cider.nrepl.middleware.info-test/sample-info-provider?}}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Besides from a function, :if could be a set of ns-qualified symbols:

:if #{clojure.core/future com.corp/my-macro ,,, }

which would mean: "this rule only applies if the symbol was found within one of these calls".

That would simplify user configs since, I reckon, most people won't want to do parsing themselves.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

info: support user-extensible documentation providers
1 participant