|
1 |
| -# Magazine app |
| 1 | +## Magazine app |
2 | 2 |
|
3 |
| -Many apps (e.g. news and blogging) will need to get fresh content from a server as a form of a bundle. In this use case: |
| 3 | +This ServiceWorker demo webapp will allow a user to view a magazine app when offline, and gain some performance benefits by pulling the 'shell' of the app from a ServiceWorker cache. This should show how ServceWorker can be used to get fresh content from a server as a form of a bundle. Here are some detailed requirements: |
4 | 4 |
|
5 |
| -* The app 'shell' is held within a ServiceWorker cache |
| 5 | +* The magazine app 'shell' is held within a ServiceWorker cache |
6 | 6 | * Some content is also held in a ServiceWorker cache or IndexedDB (this content was originally pulled from a server and displayed to the user on a previous session)
|
7 | 7 | * the app would first try to pull new content from the server
|
8 | 8 | * if succesful display to the user
|
9 |
| - * if unsuccessful the app takes the last piece of content from another ServiceWorker cache ''or'' from other storage and displays this instead. |
| 9 | + * if unsuccessful the app takes the last piece of content from another ServiceWorker cache *or* from other storage and displays this instead. |
10 | 10 |
|
11 |
| -The user may benefit from some message to say "you have the most up to date content" (or something similar and less wordy!). |
| 11 | +The user may benefit from some message to say "you have the most up to date content" (or something similar and less wordy!). In this demo you should [1] register a ServiceWorker, [2] add the 'shell' into one ServiceWorker cache [3] add some content into another ServiceWorker cache, [3] use fetching to get content from the cache or server depending on whether a connection to the server was successful. |
12 | 12 |
|
13 |
| -## Cache Age |
| 13 | +### Cache Age |
| 14 | +If the user is viewing a page which was served by a ServiceWorker cache, the user should be aware that a particular page is 30 days old and some data may not be relevant. |
14 | 15 |
|
15 |
| -The user is viewing a page which was served by a ServiceWorker cache. The user is aware that a particular page is 30 days old and some data may not be relevant. |
16 |
| - |
17 |
| -## Webfonts |
18 |
| - |
19 |
| - Page uses webfonts, want to cache web font formats used without having to cache other suggested formats. Eg, cache WOFF or TTF, not both (similar cases for media-query determined imagery). |
| 16 | +### Webfonts |
| 17 | +If the page uses webfonts we want to cache web font formats used without having to cache other suggested formats. Eg, cache WOFF or TTF, not both (similar cases for media-query determined imagery). |
| 18 | + |
| 19 | +### Questions |
| 20 | +If you have questions please ask them in the issues. Just start a new issue with your question. |
0 commit comments