-
Notifications
You must be signed in to change notification settings - Fork 54
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
Feature Request - Reverse-indexing of arrays #79
Comments
Hi @jnanasagar, thank you for this! We would support this functionality but it is not in our current scope, so if you want to take it on please do! Currently we retrieve elements from array with the underlying Thank you!! |
Hi Josh,
That's great of you. I will go ahead and create a branch and get started.
Thanks a lot.
…-Jnana.
On Tue, Jun 26, 2018 at 11:13 PM JoshKCarroll ***@***.***> wrote:
Hi @jnanasagar <https://github.com/jnanasagar>, thank you for this! We
would support this functionality but it is not in our current scope, so if
you want to take it on please do!
Currently we retrieve elements from array with the underlying
qntfy/jsonparser as seen here
<https://github.com/qntfy/kazaam/blob/master/transform/util.go#L118> so
you would want to add this functionality there and then make sure kazaam
could pick up the new version (I can take care of that part for you). I
believe the underlying code you'd want to update is here
<https://github.com/qntfy/jsonparser/blob/master/parser.go#L283-L304> and
we would also need a few new test cases to cover this in jsonparser. If
you want to submit the MR to qntfy/jsonparser and tag me I'm happy to
review.
Thank you!!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#79 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AECseLFoUDuTRG_BuFTBZkTMJPkTa9NTks5uAnLBgaJpZM4U04I2>
.
|
First of all, I would like to thank everyone for contributing to this project, it's really great and works very well. 👍
Feature :
Currently, we can access the first element of an array of JSON objects with indexing.
The first element of an array: array[0]
Nth element of an array: array[n]
Can we please add a feature to do reverse indexing of the array? This would be very useful when one would be aware of the length of an array.
Or access the last element of an array with index
-1
.I would like to take up this task if it can be accepted.
The text was updated successfully, but these errors were encountered: