Skip to content

Instantly share code, notes, and snippets.

@marcusandre
Last active December 15, 2015 07:59
Show Gist options
  • Star 7 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save marcusandre/5227116 to your computer and use it in GitHub Desktop.
Save marcusandre/5227116 to your computer and use it in GitHub Desktop.
Generate Appcache (incl. xhr) in Chrome DevTools

Generate Appcache Manifest (incl. xhr) in Chrome DevTools

  1. Open your Chrome Developer Tools
  2. Navigate to the Network tab
  3. Just right click into the panel and choose Copy ALL as HAR (maybe the page needs a reload)
  4. Switch to the console tab and save your HAR data in a variable. (var data = cmd + v)
  5. Now let's create the cache manifest:
console.log('CACHE MANIFEST\n\nCACHE:');

data.log.entries.forEach(function(entry) { 
  console.log(entry.request.url) 
});

console.log('\nNETWORK:\n*');

You did it!

@marcusandre
Copy link
Author

I suppose I have to write a Chrome plugin. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment