Reputation: 139
I have a function with one parameter like : function(a){/do something/}
if I pass a string to the function then is there any size limit of string which I can pass?
Upvotes: 3
Views: 5325
Reputation: 1
Passing by reference is always a great strategy. Passing the URI of the data resource (basically the pointer to the head of a list), dividing the data in chunks and retrieving / GET-ing the nodes in a linked list should be a good approach (look at CORS).
Upvotes: -2
Reputation: 45565
It's not defined in the standard ==> implementation dependant.
A cool resource. Cool because Crockford is the first response, and the rest of the discussion quotes other known names in the JS world.
As clarification, the limit is not going to be on the string size you can pass to the function, but just a limit on the string size that the language supports. I.e. if you have no concerns about the size of the string in one place, then passing it is fine.
Upvotes: 3