Skip to content

Instantly share code, notes, and snippets.

@alfredwesterveld
Last active July 9, 2018 14:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alfredwesterveld/a9b75e8cabb9c117b51bf4fc3084ca85 to your computer and use it in GitHub Desktop.
Save alfredwesterveld/a9b75e8cabb9c117b51bf4fc3084ca85 to your computer and use it in GitHub Desktop.
generate svg filesize
// 6MB => 6291456
const fs = require('fs');
fs.copyFileSync('svg.svg', 'long.svg');
fs.appendFileSync('long.svg', `<!--${'-'.repeat(6 * 1024 * 1024 - 96)}-->`);
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment