Skip to content

Instantly share code, notes, and snippets.

View matsumonkie's full-sized avatar

iori matsumonkie

View GitHub Profile
function ConvertGoogleDocToCleanHtml() {
var body = DocumentApp.getActiveDocument()//.getBody();
var numChildren = body.getNumChildren();
var output = [];
var images = [];
var listCounters = {};
var toc = {}
for (var i = 0; i < numChildren; i++) {
var p = body.getChild(i);