[whatwg] Cache Manifest: why have FALLBACK?

Ilkka Huotari ilkkah at gmail.com
Mon Apr 18 18:30:31 PDT 2011


This is a reply to an old discussion:
http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2009-September/023137.html

Now, I haven't probably thought this enough, but could the FALLBACK
and NETWORK be combined into one NETWORK? Both are doing pretty much
the same thing after all?

Here's how it would work:

NETWORK:
<item> [optional-fallback-item]

More specific entries would take precedence, i.e. /file.html would be
more important than /file or / or * ... Example:

NETWORK:
*
/ /offline
/file.html /offline-for-file.html

This way
- "*" would map like it does in the current spec
- "/ /offline" would map like it does in the FALLBACK section/current
spec and would take precedence over "*" because it's more specific
over *"*
- "/file.html /offline-for-file.html" would take precedence over all of these.

Benefits: Making things simpler, easier for the programmer to
understand. Faster to learn, less bugs, better code?

Ilkka


More information about the whatwg mailing list