-
-
Notifications
You must be signed in to change notification settings - Fork 653
Add pagination of long collections to inspector #1212
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
cider-inspector.el
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(interactive "nPage size: ")
is probably enough (and might be slightly more appropriate).
Looks good to me. (The clj side too). For the keys, That said, having actual |
I just noticed this, but docstrings would be nice too. Specially since they're user level commands. |
Done. I'll wait for @bbatsov to say his word about keybindings and then change them too. |
The new functionality should also be mentioned in the changelog. Btw, how did you derive the 32 default? |
By raising 2 to power of 5 ;). |
So the only question now is are we doing this as part of the current PR. I can imagine it'd be nice for this to be some |
There is a way to change it on the fly with Please also suggest a replacement for |
Yeah. The debugger does this for its object print length settings. That should be easy to do for the inspector as well.
No brilliant ideas here. I'd just suggest something that's easier to press (doesn't require the use of the little finger). |
Done with the default page size. |
I'm fine with |
cider-inspector.el
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sending nil
to nREPL will byte you, as it gets encoded as an empty vector. :-) It's best to simply not send it at all, when nil
. Here's an example.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So do I check for nil first, and if it is nil
, I don't send that value? Sounds messy. Maybe just (or
it with a hardcoded default?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's what we do everywhere. It's not ideal, but you can't simply encode EL nil
as a Clojure nil
, as it's also an empty list in Emacs Lisp, and you can never know what exactly was it used to represent.
Added a call to |
I'd say the Emacs part looks solid. Just get the Clojure tests passing and I'll have this merged. |
They are passing. Eastwood and cljfmt cannot into modern threading macros. |
Add pagination of long collections to inspector
Victory! |
🎉 |
Frontend part of the pagination feature.
Keys are arbitrary, suggestions are welcome.
.
for next page,
for previous pagez
to set a new page size inside the inspectorMissing features:
Sister pull request is clojure-emacs/cider-nrepl#238.