What's the best way use caching data in js on client side?
My application receives data from the another server, using API with limited number of requests. Data changing rarely, but may be necessary even after refresh page. What's the best solution this problem, using cookie or HTML5 WebStorage? And may be have other way to solve this task? As much as cross browser compatibility matters, cookie is the only choice rather than web storage. But the question really depends on what kind of data you are caching? For what you are trying, cookie and web-storage might not be needed at all. Cookies are used to store configuration related information, rather