Skip to content

Instantly share code, notes, and snippets.

Report from 10/6/2021, 11:42:00 AM

All unhandled elements

  • tr (799)
  • th[scope="row"] (457)
  • td (312)
  • table (231)
  • td[style="text-align: center; background-color: rgb(255, 153, 153); vertical-align: top;"] (158)
  • th[scope="row"][style="white-space: nowrap; vertical-align: top;"] (156)
  • td[style="text-align: center; background-color: rgb(204, 255, 102); vertical-align: top;"] (119)
  • kbd (117)

Report from 9/27/2021, 1:22:09 PM

All unhandled elements

  • table.properties (140)
  • kbd (96)
  • tr (73)
  • table.no-markdown (30)
  • td (29)
  • th (22)
  • table.standard-table (19)
  • td[colSpan="2"] (17)

Report from 9/22/2021, 9:23:00 PM

All unhandled elements

  • table.properties (473)
  • table.no-markdown (247)
  • sub (48)
  • table.fullwidth-table (1)

Details per Document

Missing conversion rules

  • table.properties (26:1)

Report from 9/7/2021, 4:09:12 PM

All unhandled elements

  • tr (919)
  • th[scope="row"] (784)
  • table.properties (363)
  • kbd (259)
  • table.no-markdown (226)
  • td (170)
  • table.standard-table (73)
  • th (52)
"use strict";
const fs = require("fs")
const path = require("path")
const jsdom = require("jsdom");
const { JSDOM } = jsdom;
/* get all ".html" files under the given directory into an array */

Report from 8/11/2021, 8:57:15 AM

All unhandled elements

  • tr (1199)
  • th[scope="row"] (885)
  • div.note (751)
  • span.seoSummary (405)
  • kbd (404)
  • table.properties (371)
  • div.notecard.note (330)
  • td[colSpan="3"] (285)

Report from 8/9/2021, 8:57:04 PM

All unhandled elements

  • tr (260)
  • td[style="text-align: center;"] (147)
  • th (55)
  • table.standard-table (53)
  • td[rowSpan="2"] (39)
  • td (34)
  • td[colSpan="2"] (10)
  • kbd (8)

Report from 8/9/2021, 5:57:42 PM

All unhandled elements

  • tr (260)
  • td[style="text-align: center;"] (147)
  • th (55)
  • table.standard-table (53)
  • td[rowSpan="2"] (39)
  • td (34)
  • td[colSpan="2"] (10)
  • kbd (8)
let last = 0; // last millisecond recorded
let lineno = 0; // current output line number
const iterations = 15;
let count = 0;
function timeout() {
logline(new Date().getMilliseconds());
count = count + 1;
if (count < iterations) {
setTimeout(timeout, 0);

Specifying MDN to Markdown conversion

This document describes how we'll convert MDN's HTML content into Markdown. It's focused on the JavaScript docs (https://developer.mozilla.org/en-US/docs/Web/JavaScript) because converting that is our immediate goal: however, it should be useful for converting more doc sets in the future.

It tries to take a systematic approach to conversion by listing:

  • every HTML element
  • every HTML attribute
  • every value for the class attribute encountered