The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

First off, some feedback... the book is great so far. We've been following along chapter by chapter while we develop a third-party js api for our site partners. So far the advice has been solid and all especially relevant. Alas, i think our api will need to be completed before the final chapters of this book are completed smilie ... so hopefully we don't missed anything important!

Anyway, here's a discussion we're having that I am wondering if you plan to touch on: For the initial script that is loaded, "Widget.js", how do you go about defeating browser caching when changes need to be made to that script? Are there recommended cache control settings that sort of balance performance and also allow for change? So essentially what I'm asking is: How do we update our javascript API without asking the users to update their js reference?

We are trying out a set up where we have our initial script, which is cached indefinitely. This is a light-weight script that simply makes a server call to retrieve a list of versioned files to include, and includes them all dynamically, all of which are cached indefinitely. So when a script needs to change, we just rev the script version, and include the latest version of the script, which defeats caching. But I am still concerned with having that first, initial script cached indefinitely.

Anyway, just wondering if you'll include any recommendations or discuss this topic at all.

Message was edited by:
Yes, thanks Ben. This is very helpful.