-
-
Notifications
You must be signed in to change notification settings - Fork 727
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
Make the maximum items in an array configurable. #65
Make the maximum items in an array configurable. #65
Conversation
Hi! Please read the discussion over at #55 (comment) while I look at your PR. The gist is unless the option will change the behavior of |
See #60 also.. and yeah. |
A user has also created https://www.npmjs.org/package/urlencoded-request-parser as an immediate work-around, but really you should really consider why you are creating a HTML |
So just for the sake on consistency, I'm seriously thinking of just setting |
Thanks, I'll take a look at a couple of other body parsing repos to look at possible options. Our use case was a fairly simple UI which parses a json file, displays it in a table, allows the user to make changes and then save the file back on submit [to prevent direct manipulation of the JSON]. The list size was finalised at 101 items which is where we saw the issue. |
Ok. So perhaps I'll just set the limit to... 500? :) |
Actually, I know a way to support |
The code on |
We're using body-parser to handle a large array however we hit 100 limit and got an unexpected result of the array being converted into an object.
This pull request makes the arrayLimit property configurable for use cases where there is a array larger than 100. Could potentially extend it further to validate and throw an exception if the limit is hit.