I am requesting json file every few seconds and it’s sometimes quite big, so is it possible to somehow retrieve not the whole json file, but just the last element? getJson gets the whole file.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
No, you must fetch the entire file before you can parse it and return only the last element. The best solution here is to create a new JSON file with only the information you need (if you have that ability).