jlord / sheetsee.js

:eyes: :chart_with_upwards_trend: Visualize Data from a Google Spreadsheet
jlord.github.io/sheetsee.js
Other
2.96k stars 884 forks source link

Cache? #55

Closed username1290 closed 10 years ago

username1290 commented 10 years ago

Hi, Is there a way to cache results?

jlord commented 10 years ago

@sogen server-side or in the browser? I played around with the server-side option in jlord/sheetsee-cache, but haven't touched it in a awhile as I've focused on sheetsee client-side stuff. But I haven't played with caching in the browser yet, though you should be able to save it with localStorage.

username1290 commented 10 years ago

This question arose from the time it takes to parse the data. In my tests sometimes it fails to load some of the data, showing only the first colum, and fails to load the data in the next columns.

I'm also using foreign characters in the cells, I just removed them from the headers.

I'm behind a proxy at work, don't know if that's why it fails about 2 in 10 reloads. Will check from home if it loads fine if not using a proxy.

Do you have any tips to speed it up? Thanks

username1290 commented 10 years ago

Oh, thanks I'll check the server-side script! Since the file won't change too frequently, ideally I'd like to have the data already saved/parsed to load it faster.

jlord commented 10 years ago

If it loads some but not all of the data, my guess is there is something in the spreadsheet causing the error.

The speed depends on Google and your internet -- however long it takes to fetch it from Google is how long it takes. It should return with all of the data each time. It's typically not that long but depending on your connection and amount of data, it could be slower than you want, in that case, yeah check out the caching stuff :+1: