I've found that a lot of the time that's not needed. Often you'll find the data as a JSON blob in the page and can just read it directly from there. Or find that there's an API endpoint that the javascript reads.
Load the page on it and it shows you all the request being made along with the payload as it happens.
Find the one you need, copy the data, endpoint and HTTP verb and recreate it in your language of choice :D