remove fireWhenReady timeout, and use script loaded event

### Problem

Used a timeout to check if all the scripts were loaded.

### Solution

Used a 'load' event and a count to check if the all the scripts were loaded, then fires the markdown to html conversion.