Recursively search for keys and apply custom sort #2279
Unanswered
jacobbednarz
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have the following working to give me a predefined sort order with the remainder keys at the end.
Before
After
However, I need to apply it recursively and I don't always know what level the
.methods
will be at. Any guidance on the best approach to traversing to find.methods
and modify it regardless of nesting level?Full example
Expected outcome
I did try with
.. | select(has("methods"))
however, that is giving some unexpected output (basically each iteration and nesting level) instead of just the thing i'm looking to update adding to the confusion.Beta Was this translation helpful? Give feedback.
All reactions