PDA

View Full Version : Timestamp at the end of CSS and JS url breaking cache in production?



lestu
11 Nov 2012, 11:32 AM
Hi there

I have the problem that in production build, in the Chrome network console, the urls for app.css and app.js look like this:
/test/branches/sencha2/build/production/resources/css/app.css?1352661930189
/test/branches/sencha2/build/production/app.js?1352661930192

Why is that? Doesn't that defeat the purpose of the local storage?

Also, I notice that after a reload, app.js seems not to be loaded again, but app.css is loaded every time.

Relevant parts from app.json:

"css": [
{
"path": "resources/css/app.css",
"update": "delta"
}
],


"appCache": {
/**
* List of items in the CACHE MANIFEST section
*/
"cache": [
"index.html",
"app.js",
"resources/css/app.css"
],

What am I missing?

Thanks,
Lestu

lestu
12 Nov 2012, 2:21 AM
The reason for the CSS file missig in cache was that is was much too big (3.8 MB) because of many embedded images, where webkit browsers have a max. file size of 2.5 MB that they will put in cache.

But the question remains: Why are there timestamps on the URLs in production? How can they be turned off?

Thanks,
Lestu

lestu
13 Nov 2012, 5:13 AM
Hello anybody? :-/