Skip to content

Instantly share code, notes, and snippets.

View autonomobil's full-sized avatar

Moritz Cremer autonomobil

View GitHub Profile
@PeteBlackerThe3rd
PeteBlackerThe3rd / getline_async.h
Last active May 6, 2023 23:53
drop in non-blocking replacement for std::getline
#include <iostream>
bool getline_async(std::istream& is, std::string& str, char delim = '\n') {
static std::string lineSoFar;
char inChar;
int charsRead = 0;
bool lineRead = false;
str = "";
@shufengh
shufengh / LocalStorageExport.md
Created July 11, 2019 05:23
How to export content in Chrome's local storage for a website

Original idea is from this post

  1. Open a tab and navigate to the website where you have content to export.

  2. Open devtools and switch to the console tab.

  3. Copy and paste the following snippet in the console and Chrome should ask you to save the output file

var obj = JSON.stringify(localStorage, null, 4)